Comments (3)
There is an issue with getting the proper content files from NPM.
Go into YOUR node_modules => react-native-share-extension => ios => ReactNativeShareExtension.m
I'm guessing your version of that file ^^ does not match the file in the link you pasted above.
I just created a new project to test this issue and the proper files didn't come from NPM. After pasting the proper file in, all is well...
-Dan
import React from 'react'
import Alert from 'rn-animate-alert'
import { View,Text,TouchableOpacity } from 'react-native'
import ShareExtension from 'react-native-share-extension'
export default class Share extends React.Component {
constructor(){
super()
this.state = {
show: false,
type: '',
value: '',
}
}
async componentDidMount(){
try {
let { type, value } = await ShareExtension.data()
this.setState({type:type,value:value, show:true})
} catch (e){
console.log(e)
}
}
close = () => {
this.setState({show:false}, () => ShareExtension.close() )
}
render(){
let { type, value, show } = this.state
return(
<Alert
show={ show }
entrance={ 'fromBottom' }
backgroundColor={ 'rgba(111,111,111,.7)' }
>
<View style={{
marginVertical:100,
marginHorizontal:30,
backgroundColor:'white',
padding:10,
alignItems:'center',
justifyContent:'center',
flex:1,
}}>
<Text>{type}</Text>
<Text>{value}</Text>
<TouchableOpacity onPress={ this.close }>
<Text>{'CLOSE'}</Text>
</TouchableOpacity>
</View>
</Alert>
)
}
}
from react-native-share-extension.
@parkerdan I feel silly for not picking up on this myself 😅 Thank you for pointing this out! Maybe I should file an issue asking for @alinz to do a fresh npm publish
?
from react-native-share-extension.
@louiscenter I have publish to npm, this should be fixed now.
from react-native-share-extension.
Related Issues (20)
- Issue HOT 5
- Sharing from browser: real iOS device receives page title, simulators receive URL HOT 2
- Video File Issue? HOT 1
- Audio and Video share empty value problem HOT 5
- not able to share image from google photos when app in background HOT 1
- Share extension opens up different instance of application HOT 4
- This no longer works HOT 10
- Error after clicking on my app icon during sharing (Expokit, Android) HOT 1
- 0.62.2 (Podspec) HOT 1
- 0.62.2 issue HOT 2
- 🔥How to clear image from bundle when app goes in background after receiving image prop HOT 1
- Working in React Native 0.62.2 (iOS) HOT 18
- What file extensions are allowed? HOT 1
- ERROR: File not found #import "React/RCTBridgeModule.h" HOT 1
- Cannot find lDoubleConversion HOT 1
- share ActionExtension not working with firebase
- expo-dev-client / EAS build integration? HOT 1
- Not getting Url when sharing image from Google to share extension ( Android)
- Cant share screenshot on ios
- Invariant Violation: "passages" has not been registered. This can happen if:
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from react-native-share-extension.