You've already forked joplin
mirror of
https://github.com/laurent22/joplin.git
synced 2025-06-15 23:00:36 +02:00
19
ReactNativeClient/lib/ShareExtension.ts
Normal file
19
ReactNativeClient/lib/ShareExtension.ts
Normal file
@ -0,0 +1,19 @@
|
||||
const { NativeModules, Platform } = require('react-native');
|
||||
|
||||
export interface SharedData {
|
||||
title?: string,
|
||||
text?: string,
|
||||
resources?: string[]
|
||||
}
|
||||
|
||||
const ShareExtension = (Platform.OS === 'android' && NativeModules.ShareExtension) ?
|
||||
{
|
||||
data: () => NativeModules.ShareExtension.data(),
|
||||
close: () => NativeModules.ShareExtension.close(),
|
||||
} :
|
||||
{
|
||||
data: () => {},
|
||||
close: () => {},
|
||||
};
|
||||
|
||||
export default ShareExtension;
|
Reference in New Issue
Block a user