本文介绍了可以在浏览器中测试 React Native 应用程序吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

意识到 React Native 应用程序旨在使用模拟器进行开发/测试,是否可以使用网络浏览器来测试应用程序?

Realizing that React Native apps are designed to be developed / tested using simulators, is it possible to use a web browser to also test an application?

存在诸如 https://rnplay.org/ 之类的服务,但我担心的是它由 它可能受到每月分钟数的限制.与付费屏幕流媒体服务相比,我还想利用免费/开源技术来实现这一点.

Services such as https://rnplay.org/ exist, however my concern is it's powered by https://appetize.io/ it might be limited by the # of minutes per month. I'd also like to utilize free / open-source technology to accomplish this, as compared to a paid screen streaming service.

沿着这些思路,为了在浏览器中测试应用程序,应用程序是否需要使用一个或多个库来允许应用程序在 React Native 和简单的 React 中运行?我想找到这种特定方法的替代方法,因为我想专门为 React Native 编写代码.

Along these lines, in order to test the app in a browser, would the app be required to use one or more libraries which allow the app to be run in both React Native and also simply React? I'd like to find an alternative to this particular approach as I'd like to code for React Native specifically.

推荐答案

不能,React Native 只能在 IOS 和 Android 等移动模拟器上测试

No, React Native can be tested only in mobile simulators like IOS and Android

更新:Facebook 为 React Native 提供了一个漂亮的入门包.

Update:Facebook has given a beautiful starter pack for React native.

介绍创建反应原生应用

使用它,您可以使用 expo app(https://expo.io) 在您的手机上运行该应用程序.它使用二维码同步.

Using this you can run the app in your mobile using expo app(https://expo.io) .It syncs using QR code.

这篇关于可以在浏览器中测试 React Native 应用程序吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-18 12:14