[英]I would like to know how to make automatic refresh instead of pressing a button in Expo/React Native
So I'm new to react native and Expo and i would like to know a way to automatize my screen when i receive an order to update the screen every time.所以我是新来的反应原生和 Expo 我想知道当我收到每次更新屏幕的命令时自动化我的屏幕的方法。
My Code:
https://pastebin.com/eqJtay50 My Code:
https://pastebin.com/eqJtay50
you have to send notification to you app each time on server you receive an order ( you can use react-native-firebase...).每次在服务器上收到订单时,您都必须向您的应用发送通知(您可以使用 react-native-firebase ...)。 then in your app, when receive notification, you call api to reload screen ( may use redux-thunk, redux-saga....)然后在您的应用程序中,当收到通知时,您调用 api 重新加载屏幕(可能使用 redux-thunk、redux-saga ......)
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.