将现有的 React Native 项目转换为 Expo [英] Converting Existing React Native Projects to Expo

查看:19
本文介绍了将现有的 React Native 项目转换为 Expo的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在考虑使用 Expo 在 React Native 中构建移动应用程序,我在常见问题解答中注意到现有的 React Native 项目可以转换为 Expo.

I'm considering building mobile apps in React Native using Expo and I noticed under FAQ that existing React Native projects can be converted to Expo.

我们究竟在转换什么?我真的很喜欢尽可能保持纯粹和干净,中间没有太多抽象层,这会掩盖我理解应用程序中真正发生的事情的能力.

What exactly are we converting? I really like staying as pure and clean as possible without too many abstraction layers in the middle which can obscure my ability to understand what's really happening for things to work in the app.

我希望能对转换过程中真正发生的事情以及 Expo 为现有项目添加的内容提供更多说明.

I'd appreciate a bit more clarification about what's really happening in the conversion process and what Expo is adding to the existing project.

推荐答案

Expo XDE 自述文件.

但是,我们没有让它工作,并决定将我们的代码移植到默认的 Expo 应用程序中(编辑:在将我们的应用程序移植到 Expo 时遇到很多问题后,我们决定恢复到香草RN).

However, we didn't get it working and decided to port our code into the default Expo app (Edit: after hitting a lot of issues porting our app to Expo, we decided to revert to vanilla RN).

文档中至少缺少一些必需的步骤:

There are at least a few required steps missing from the documentation:

  • 创建 exp.json 文件
  • 将 React 和 React Native 库更新到 Exponent 所需的版本

  • Create exp.json file
  • Update React and React Native libraries to the versions required by Exponent

"react": "16.0.0-alpha.6","react-native": "https://github.com/expo/react-native/archive/sdk-16.0.0.tar.gz",

我们 在我们的博客上总结 为什么我们放弃了目前形式的世博会.

We summarized on our blog why we gave up on Expo in its current form.

这篇关于将现有的 React Native 项目转换为 Expo的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆