Skip to content

Commit

Permalink
ios: fix session csv download
Browse files Browse the repository at this point in the history
  • Loading branch information
naltatis committed Aug 19, 2024
1 parent 593ddeb commit f402a63
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions screens/MainScreen.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -114,6 +114,10 @@ export default function MainScreen({ navigation }) {
setIsConnected(false);
}, []);

const onFileDownload = ({ nativeEvent: { downloadUrl } }) => {
if (downloadUrl) Linking.openURL(downloadUrl);
};

const LoadingScreenMemoized = useMemo(() => <LoadingScreen />, []);

const LayoutMemoized = useMemo(
Expand Down Expand Up @@ -142,6 +146,7 @@ export default function MainScreen({ navigation }) {
onContentProcessDidTerminate={onTerminate}
onMessage={handleMessage}
onShouldStartLoadWithRequest={onShouldStartLoadWithRequest}
onFileDownload={onFileDownload}
/>
</Animated.View>
<Animated.View
Expand Down

0 comments on commit f402a63

Please sign in to comment.