- html - 出于某种原因,IE8 对我的 Sass 文件中继承的 html5 CSS 不友好?
- JMeter 在响应断言中使用 span 标签的问题
- html - 在 :hover and :active? 上具有不同效果的 CSS 动画
- html - 相对于居中的 html 内容固定的 CSS 重复背景?
一直致力于通过 create-react-native-app
生成的项目.已成功使用该项目一段时间,但现在尝试通过 exp start --tunnel
测试该应用程序,我突然看到以下形式的错误(虽然以前工作过):
[22:08:19] /path/to/node_modules/react-native-scripts/build/bin/crna-entry.js: Plugin/Preset files are not allowed to export objects, only functions. In /path/to/node_modules/babel-preset-expo/index.js
[22:08:19] Failed building JavaScript bundle.
bable
是的,所以我很难理解如何将这些帖子应用于我自己的情况。
{
"presets": ["babel-preset-expo"],
"env": {
"development": {
"plugins": ["transform-react-jsx-source"]
}
}
}
npm cache clean --force && rm -rf node_modules && rm -f package-lock.json && npm install
没有变化。
似乎有帮助的是将 react-native@0.56 降级到 0.55 (正如这里所支持的:
Create React Native App. - Plugin/Preset files are not allowed to export objects, only functions ),但这似乎并没有直接解决问题,而是一种解决方法。任何关于这里应该做什么的建议将不胜感激(应该包含任何其他文件来帮助调试?)。
最佳答案
发现问题是这样的:
在某些时候,一定做了一个 npm update
将 react-native 更新为 0.56,将 expo 更新为 28.0.0。
查看 react-native 文档( https://facebook.github.io/react-native/docs/upgrading.html#create-react-native-app-projects ),react-native 似乎是 需要安装 react-native
的版本, react
, 和 expo
彼此特别兼容 .可以在此处找到哪些软件包的哪些版本相互兼容的矩阵:https://github.com/react-community/create-react-native-app/blob/master/VERSIONS.md并说
Each version of these dependencies is only compatible with a narrow version range of the other two.
...
"dependencies": {
"@expo/vector-icons": "^6.3.1",
"eslint": "^4.19.1",
"expo": "^27.1.0",
"prop-types": "^15.6.2",
"react": "16.3.1",
"react-native": "^0.55.4",
"react-native-mail": "^3.0.6",
"react-native-modal-dropdown": "^0.6.2",
"react-navigation": "^2.6.2",
"react-redux": "^5.0.7",
"redux": "^4.0.0",
"tcomb-form-native": "^0.6.14",
"uuid": "^3.3.2"
}
}
关于react-native - 在 create-react-native-app 项目中突然看到错误 "Plugin/Preset files are not allowed to export objects, only functions",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/51241109/
如何获取特定 UTF-8 字符串的字节序列?我看到正则表达式引擎中的某些错误仅在某些边缘情况下才会触发,我想确切地知道它正在处理哪些数据。 最佳答案 也许 charToRaw ? > charToRa
考虑一个具有许多变量的 java 程序,其中一些是循环计数器,我希望看到这些变量随时间变化的值,而不是在代码中到处放置 print 语句。 为什么?我认为它可以帮助我轻松调试。 Example- in
有没有办法查看 JavaScript 正在创建的“线程”?例如,如果我有一个附加到 DOM 元素的事件处理程序,我假设 JavaScript 会隐式地创建一个新线程来在后台运行该代码?如果是这样,有没
我正在使用反射 API 来调用类运行时并调用其方法。但我看到 java.lang.reflect.InitationTargetException 异常。 我需要调用一个名为 - TestClass
考虑一个名为 t.cmd 的命令脚本,它只包含以下两行: @exit /b 123 @echo If you see this, THEN EXIT FAILED.. 因此,该脚本只是将脚本执行过程的
我最近一直在努力学习编程语言实用学第 3 版,以了解更多关于语言在底层如何工作的信息,并且通过查看由真正基本的 GCC 编译的 C 代码生成的程序集,我获得了很多进展.我开始对 C 系列的静态语言越来
最简单的制作方法是什么QWebView识别并正确加载网页上的 Flash? 最佳答案 似乎只需两行即可实现(当然,假设目标系统上安装了闪存): QWebSettings *settings = QWe
我想通过编程(使用VBA)访问其他人与我共享的日历。它们在我的Outlook中的“人民日历”下列出。我在网上搜索了此内容,所有建议所做的仅使我感到困惑。如何从“人的日历”中获取共享给我的所有日历的
使用MongoDB Compass,可以看到数据库用户或创建新用户吗? 最佳答案 香港专业教育学院在命令行上使用以下命令进行管理: mongo use (my database name) db.cr
我正在CentOS 7.4.1708(核心),Java(TM)SE运行时环境(内部版本1.8.0_152-b16)上运行eXist-db 3.6.1。我希望能够在person.xml中的最后一个记录之
我需要确认。 客户端 1 在事务内的表中插入行。 客户端 2 使用 SELECT 请求该表。如果在此客户端上隔离级别设置为 READ COMMITTED,您能否确认 SELECT 不会返回客户端 1
我刚刚安装了 python-dev: $ sudo apt-get install python-dev 这样我就可以开始使用 P4Python 了。但是当我尝试导入 P4 时,我得到: Traceb
我正在使用 msys 和 mingw 编译 libtorrent-rasterbar-0.16.16。./configure 运行良好,直到它进入 boost 库检查。我有 boost 1.51,我设
我在 GO 项目的 Travis CI 上有一个奇怪的行为。 [这里] 失败了,提示一个函数只接受 1 个参数并用 2 个参数调用。 src/finances-service/main.go:45:1
这个问题已经有答案了: What are enums and why are they useful? (27 个回答) 已关闭 4 年前。 作为 Java 初学者,我接触到了枚举,这让我对类型声明感
关闭。这个问题是off-topic .它目前不接受答案。 想改进这个问题吗? Update the question所以它是on-topic用于堆栈溢出。 关闭 11 年前。 Improve thi
我正在使用 preactjs 创建我的应用程序。最重要的是,我正在使用剑道网格。在网格内,我想显示一个超链接。如果用户点击链接,它应该改变路线。为了呈现链接,我使用了 preact-router。 这
有没有办法只查看 Node.js 中的函数签名?我知道 fn.toString() 但不需要所有代码,只需要签名。 最佳答案 var source = fn.toString(); var signa
如何设置 vim 以查看我在 ubuntu 上安装的 ruby rvm。 rvm 已安装,ruby 从终端返回。 renshaw@renshaw-TravelMate-5740G:~$ ruby
我试图在我的 Android 应用程序中防止 OutOfMemoryError。我已经阅读了很多帖子,但我仍然无法解决。 该应用程序有后台 Activity ,所以我认为这是主要问题。 OutOfMe
我是一名优秀的程序员,十分优秀!