Expo

Documentation

Sharing

This module allows sharing files.

Platform Compatibility

Android DeviceAndroid EmulatoriOS DeviceiOS SimulatorWeb

For managed apps, you'll need to run expo install expo-sharing. To use it in a bare React Native app, follow its installation instructions.

import * as Sharing from 'expo-sharing';

Opens action sheet to share file to different applications which can handle this type of file.

Arguments

  • url (string) -- Local file URL to share.
  • options (object) --
    A map of options:
    • mimeType (string) -- sets mimeType for Intent (Android only)
    • dialogTitle (string) -- sets share dialog title (Android and Web only)
    • UTI (string) -- (Uniform Type Identifier) the type of the target file (iOS only)