From b8b3ba8fcf7cec6810d8eaa49a9cd1898e189fe8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20KERISIT?= Date: Thu, 30 May 2024 13:45:21 +0200 Subject: [PATCH] add avoid keep awake examples --- src/avoid-keep-awake-react-native-fn.js | 25 +++++++++++++++++++++++ src/avoid-keep-awake-react-native-hook.js | 13 ++++++++++++ 2 files changed, 38 insertions(+) create mode 100644 src/avoid-keep-awake-react-native-fn.js create mode 100644 src/avoid-keep-awake-react-native-hook.js diff --git a/src/avoid-keep-awake-react-native-fn.js b/src/avoid-keep-awake-react-native-fn.js new file mode 100644 index 0000000..c508f95 --- /dev/null +++ b/src/avoid-keep-awake-react-native-fn.js @@ -0,0 +1,25 @@ +import { activateKeepAwake, deactivateKeepAwake } from 'expo-keep-awake'; +import React from 'react'; +import { Button, View } from 'react-native'; + +export default class KeepAwakeExample extends React.Component { + render() { + return ( + +