Skip to content

Commit

Permalink
fix: made react-native-share an optional dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
ximxim committed May 31, 2021
1 parent 0bfd7a7 commit 45f6206
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions example/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ PODS:
- React-cxxreact (= 0.63.4)
- React-jsi (= 0.63.4)
- React-jsinspector (0.63.4)
- react-native-feedback-reporter (0.2.13):
- react-native-feedback-reporter (0.3.0):
- React-Core
- React-RCTActionSheet (0.63.4):
- React-Core/RCTActionSheetHeaders (= 0.63.4)
Expand Down Expand Up @@ -489,7 +489,7 @@ SPEC CHECKSUMS:
React-jsi: a0418934cf48f25b485631deb27c64dc40fb4c31
React-jsiexecutor: 93bd528844ad21dc07aab1c67cb10abae6df6949
React-jsinspector: 58aef7155bc9a9683f5b60b35eccea8722a4f53a
react-native-feedback-reporter: c9bafc435a08f21034fc4f01e362042f6658becb
react-native-feedback-reporter: b25d225ea299daedf0cf880ef404901eb18f37d9
React-RCTActionSheet: 89a0ca9f4a06c1f93c26067af074ccdce0f40336
React-RCTAnimation: 1bde3ecc0c104c55df246eda516e0deb03c4e49b
React-RCTBlob: a97d378b527740cc667e03ebfa183a75231ab0f0
Expand Down
2 changes: 1 addition & 1 deletion src/hooks/useRNShare.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
import { useContext, useCallback, useEffect } from 'react';
import Share from 'react-native-share';
import { NativeModules } from 'react-native';
import { useFormContext } from 'react-hook-form';

Expand Down Expand Up @@ -32,6 +31,7 @@ export const useRNShare = ({ files }: IUseRNShareProps) => {
],
devNotes,
});
const Share = require('react-native-share').default;
Share.open({
title: 'Share file',
failOnCancel: false,
Expand Down

0 comments on commit 45f6206

Please sign in to comment.