简体   繁体   中英

Change screens depending on the OS with React Native

我正在开发一个使用 Health Kit 和 Google fit 的应用程序,我有一个屏幕要求用户允许跟踪数据,如何使系统与 Android 和 iOS 不同,以将用户发送到正确的页面?

You can use property of Platform.OS and do your changes according to that. For example

color:Platform.OS === 'ios'? 'red':'yellow' color:Platform.OS === 'ios'? 'red':'yellow' .

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM