0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 5 years have passed since last update.

ActionSheetIOS.showShareActionSheetWithOptions()で、画像を保存が表示されない

Posted at

結論

showShareActionSheetWithOptions()は、リモートファイルを指定することができない模様

詳細

以下のように記述していた。
Activity View Controllerは表示されるが、「画像を保存」が表示されずに困っていた。
urlの部分をローカルファイルパスに変更したところ、「画像を保存」や「共有アルバム(フォトライブラリ)」が現れてくれた。

<View style={styles.isCenter}>
  <Button
    title="save"
    onPress={Platform.OS === 'ios'
      ? () => ActionSheetIOS.showShareActionSheetWithOptions(
        { url: 'https://facebook.github.io/react-native/img/header_logo.png' },
        () => {},
        () => console.tron.log('success.'),
      ) : () => {
        // abbreviation for android
      }
    }
  />
</View>
0
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
1

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?