简体   繁体   English

我想知道如何进行自动刷新而不是在 Expo/React Native 中按下按钮

[英]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.

相关问题 大家好我想制作一个单选按钮并通过在 React 中按 Enter 键将其设为 select - Hello everyone I would like to make a radio button and make it select by pressing Enter key in React 我将如何像这样在 react Native 中进行自定义开关和切换 - How would I make a Custom Switch and Toggle Like this In react Native 如何使用 React Native 制作类似于 Instagram 的点赞功能(如按钮) - How to make a like function similar to Instagram (like button) with react native 如何在React Native Expo中使用按钮发送通知 - How to send notification with button in react native expo React Native Expo - 禁用自动更新 - React Native Expo - Disable Automatic Update 我想知道如何只显示集合中的一个特定元素,而不显示整个集合 - I would like to know how to display only one specific element of the collection instead of the whole collection React Native Navigation,按下警报按钮后如何导航到另一个屏幕? - React Native Navigation, How do I navigate to another screen after pressing the button of an alert? 反应本机应用程序,按android-phone后退按钮应该刷新上一个页面或组件? - React native app, pressing android-phone back-button should refresh previous page or component? 我想知道一些关于如何托管和上传完整网站的事情,包括(服务器、反应、mysql) - i would like to know few things about how to host and upload full website include(server ,react, mysql) 按下按钮后在 React 中重新填充/刷新表 - Repopulating/Refresh table in React after pressing a button
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM