Share photo to Instagram from React-Native app built with Expo SDK

前端 未结 4 1414
南笙
南笙 2020-12-29 17:17

I want my react-native app to share a photo with Instagram. I know it\'s possible when writing in native code to open up Instagram\'s filter screen with a specified photo.

4条回答
  •  抹茶落季
    2020-12-29 17:50

    Worked For Me :)

    onClick = () => {
      ImagePicker.launchImageLibrary(options, response =>{
        console.log(response);
        let instagramURL = `instagram://library?LocalIdentifier=`+response.origURL;
        Linking.openURL(instagramURL);
      })
    

提交回复
热议问题