在从Reactive0.22.2升级并升级了几个插件之后,我开始在iOS上得到这个错误。我试过降级和重新安装所有的东西,但我无法摆脱,修复它。其他任何人都会遇到这样的情况:
SyntaxError: Strict mode does not allow function declarations in a lexically nested statement.
更新1:
除了恢复模块之外,我还注释掉了所有的'use strict';
我更新的内容之一是npm和节点。我正在运行nodev5.3.0和npmv3.8.3。我不记得我有什么版本..。
更新2:
下面是我在react本机
我正在配置一个新项目,并且已经开始导入一些库,这时我得到了以下流错误。这个错误是什么意思,我该如何诊断和修复?这是一个react原生项目,我最近添加了subscriptions-transport-ws库。
Launching Flow server
Spawned flow server (pid=13272)
node_modules/react-native/Libraries/Renderer/src/renderers/shared/stack/event/eventPlugins/TouchHistoryMath.js:0
TouchHistoryMath. Duplicate m
在您尝试自动删除此副本之前,请听我说完。我花了一整天在谷歌上搜索并尝试了所有的方法。
我的项目是一个使用Expo的React Native应用程序。
最近,当我添加一些包以使测试正常工作时,我开始收到这个错误:
Invariant Violation: NetInfo has been removed from React Native. It can now be installed and imported from '@react-native-community/netinfo' instead of 'react-native'. See https
我正在尝试在现有的React Native项目上设置测试。当我使用Jest运行测试时,测试失败并显示以下错误:
Test suite failed to run
...etc/__app__/node_modules/react-native/Libraries/polyfills/error-guard.js:14
type ErrorHandler = (error: mixed, isFatal: boolean) => void;
^^^^^^^^^^^^
SyntaxError: Unexpected identifier
我正在将我的node.js更新到版本7。在项目中运行了webpack之后,我收到了错误消息:ERROR in Path must be a string. Received undefined
我的package.json:
"dependencies": {
"react": "^15.3.1",
"react-native": "^0.33.0",
"react-redux": "^4.4.5",
"react-web": "
我目前正在学习React Native中的一些redux。但是,如果我试图在一个index.js文件中组合我的reducers,我总是会遇到一个错误。
(0, _redux.combineReducers) is not a function
我看了一些如何使用它的教程,我遵循了每一步,但它一直出现在我的屏幕上。
我的App.js看起来像这样:
import React, { Component } from 'react';
import { Platform, StyleSheet, Text, View } from 'react-native';
imp
所以我试着用Jest和TypeScript在我的上编写测试。虽然使用旧的babel版本一切都很好,但是由于一些项目问题,我们不得不将babel升级到7.0.0。从那以后我就没办法了。任何帮助都是非常感谢的。
Jest Jest遇到了一个意想不到的标记--这通常意味着您试图导入Jest无法解析的文件,例如,它不是普通的。默认情况下,如果Jest看到Babel配置,它将使用该配置来转换文件,而忽略"node_modules".。
/home/levan/work/vabaco-dhp-frontend/packages/dhp-mobile-app/node_modules/rea
我见过这个问题被问了好几次,但似乎没有任何答案能解决我的问题(有些答案现在可能已经过时了)
我有一个进程正在使用8081端口,这是我无法杀死的。所以我不得不:
react-native start --port 8082
到目前一切尚好。
关于iOS的问题
当我执行react-native run-ios时,我在终端Port 8081 already in use, packager is either not running or not running correctly.中得到以下错误。我已经看到多个答案在AppDelegate.m中说要更改某些内容,但是在该文件中没有任何声明端口的内容