【发布时间】:2019-08-08 09:18:36
【问题描述】:
“我对这一切都很陌生,这是我第一个发布的问题!我正在开发 react-native Android 应用程序。构建应用程序后,它向我显示一个错误 - 在 react-native 中出现意外令牌'{' , import call 只需要一个参数。 我已经检查了很多次我的源代码,但我没有任何与此错误相关的解决方案。我该怎么办??
这是我的 pakage.json 文件-
{ "name": "myapp",
"version": "1.2.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"dependencies": {
"@react-native-community/async-storage": "^1.4.2",
"@react-native-community/netinfo": "^3.2.1",
"jetifier": "^1.0.1",
"native-base": "^2.12.1",
"prop-types": "^15.6.1",
"react": "16.6.3",
"react-native": "^0.59.8",
"react-native-datepicker": "^1.7.2",
"react-native-device-info": "^2.0.2",
"react-native-elements": "^1.1.0",
"react-native-fbsdk": "0.8.0",
"react-native-firebase": "^5.2.3",
"react-native-gesture-handler": "^1.1.0",
"react-native-google-signin": "^1.2.1",
"react-native-image-picker": "^0.28.0",
"react-native-otp-inputs": "^2.0.1",
"react-native-paper": "^2.14.0",
"react-native-popup-dialog": "^0.17.0",
"react-native-razorpay": "^2.1.23",
"react-native-tab-view": "^1.3.2",
"react-native-vector-icons": "^6.4.1",
"react-native-webview": "^6.3.0",
"react-navigation": "^3.3.2",
"react-navigation-material-bottom-tabs": "^1.0.0",
"react-navigation-transitions": "^1.0.10"
},
"devDependencies": {
"babel-core": "7.0.0-bridge.0",
"babel-jest": "24.4.0",
"babel-plugin-transform-remove-console": "^6.9.4",
"jest": "24.4.0",
"metro-react-native-babel-preset": "0.53.0"
},
"jest": {
"preset": "react-native"
},
"rnpm": {
"assets": [
"./assets/fonts/"
]
}
}
这是我在手机上构建应用程序后遇到的错误
【问题讨论】:
-
提供错误代码。
标签: react-native import token react-native-android