After archive react-native ios appication, I had test it on Immuniweb mobile application testing tool. I have got security issue given bellow.
EXPOSURE OF POTENTIALLY SENSITIVE DATA [DAST] [M2] [CWE-200]
Potentially sensitive or internal information is detected in the mobile application via tracing its system calls.
[POTENTIAL HEROKU API KEY FOUND]
We did not use HEROKU anyway.
This is my package.json contents.
{
"name": "",
"version": "0.0.1",
"private": true,
"scripts": {
"postinstall": "rn-nodeify --install fs,util,path,tls,stream,buffer,global,process --hack && patch-package",
"android": "ENVFILE=.env react-native run-android",
"start": "react-native start",
"test": "jest",
"lint": "eslint .",
"build:ios": "react-native bundle --entry-file='index.js' --bundle-output='./ios/main.jsbundle' --dev=false --platform='ios'"
},
"dependencies": {
"#gorhom/bottom-sheet": "^4.4.3",
"#invertase/react-native-apple-authentication": "^2.2.2",
"#react-native-async-storage/async-storage": "^1.17.9",
"#react-native-community/checkbox": "^0.5.12",
"#react-native-community/cli": "^8.0.5",
"#react-native-community/datetimepicker": "^6.3.2",
"#react-native-community/push-notification-ios": "^1.10.1",
"#react-native-masked-view/masked-view": "^0.2.6",
"#react-native-picker/picker": "^2.4.4",
"#react-navigation/bottom-tabs": "^6.3.2",
"#react-navigation/native": "^6.0.10",
"#react-navigation/stack": "^6.2.1",
"#rneui/base": "^0.0.0-edge.2",
"#rneui/themed": "^0.0.0-edge.2",
"#types/jest": "^29.0.0",
"asyncstorage-down": "^4.2.0",
"aws-iot-device-sdk": "^2.2.12",
"aws-sdk": "^2.1203.0",
"axios": "^0.27.2",
"buffer": "^4.9.1",
"global": "^4.4.0",
"jsonwebtoken": "^8.5.1",
"jwt-decode": "^2.2.0",
"lodash.clonedeep": "^4.5.0",
"lodash.get": "^4.4.2",
"lodash.isempty": "^4.4.0",
"lodash.max": "^4.0.1",
"lodash.min": "^4.0.1",
"lodash.omit": "^4.5.0",
"lodash.unionby": "^4.8.0",
"moment": "^2.29.4",
"patch-package": "^6.4.7",
"path-browserify": "0.0.0",
"process": "^0.11.0",
"react": "18.0.0",
"react-native": "^0.69.2",
"react-native-config": "^1.4.6",
"react-native-date-picker": "^4.2.5",
"react-native-device-info": "^10.0.2",
"react-native-encrypted-asyncstorage": "^2.1.3",
"react-native-flash-message": "^0.3.1",
"react-native-fs": "^2.20.0",
"react-native-gesture-handler": "^2.4.2",
"react-native-iap": "^11.0.0-rc.7",
"react-native-modal-datetime-picker": "^14.0.0",
"react-native-pager-view": "^6.0.0",
"react-native-paper": "^4.12.4",
"react-native-picker-select": "^8.0.4",
"react-native-progress": "^5.0.0",
"react-native-push-notification": "^8.1.1",
"react-native-reanimated": "^2.13.0",
"react-native-safe-area-context": "^4.3.1",
"react-native-screens": "^3.15.0",
"react-native-svg": "^12.4.3",
"react-native-tab-view": "^3.1.1",
"react-native-vector-icons": "^9.2.0",
"react-native-webview": "^11.25.0",
"react-redux": "^7.2.2",
"readable-stream": "1.0.33",
"reanimated-bottom-sheet": "^1.0.0-alpha.22",
"redux": "^4.2.0",
"redux-logger": "^3.0.6",
"redux-persist": "^6.0.0",
"redux-saga": "^1.1.3",
"rn-swipe-button": "^1.3.7",
"save": "^2.4.0",
"stream": "^0.0.2",
"stream-browserify": "^1.0.0",
"toggle-switch-react-native": "^3.3.0",
"util": "~0.10.3",
"victory-native": "^36.5.3"
},
"devDependencies": {
"#babel/core": "^7.12.9",
"#babel/runtime": "7.13.8",
"#react-native-community/eslint-config": "1.1.0",
"babel-jest": "25.5.1",
"eslint": "^8.23.0",
"eslint-config-prettier": "^8.5.0",
"eslint-plugin-prettier": "^4.2.1",
"jest": "^28.1.1",
"metro-react-native-babel-preset": "^0.70.3",
"prettier": "^2.7.1",
"react-test-renderer": "18.0.0",
"rn-nodeify": "^10.3.0"
},
"jest": {
"preset": "react-native"
},
"rnpm": {
"assets": [
"./app/assets/fonts"
]
},
"react-native": {
"path": "path-browserify",
"_stream_transform": "readable-stream/transform",
"_stream_readable": "readable-stream/readable",
"_stream_writable": "readable-stream/writable",
"_stream_duplex": "readable-stream/duplex",
"_stream_passthrough": "readable-stream/passthrough",
"stream": "stream-browserify",
"tls": false,
"fs": "react-native-fs"
},
"browser": {
"path": "path-browserify",
"_stream_transform": "readable-stream/transform",
"_stream_readable": "readable-stream/readable",
"_stream_writable": "readable-stream/writable",
"_stream_duplex": "readable-stream/duplex",
"_stream_passthrough": "readable-stream/passthrough",
"stream": "stream-browserify",
"tls": false,
"fs": "react-native-fs"
}
}
I need help to overcome this security issue?
Related
I have no Component like ListView, Icon, Spinner, and others stuff, but it's still getting back the Invariant violation error in my react native project. Can anybody help me? I added my package.json file here. When I type "npm list" in my terminal I get some npm error like the image two. I'm not sure if this problem is happening for my image two errors.
{
"name": "eon-bazar",
"description": "MStore Pro - Complete React Native template for e-commerce",
"author": "InpireUI",
"version": "1.0.0",
"private": true,
"main": "node_modules/expo/AppEntry.js",
"scripts": {
"setup": "./scripts/setup.sh",
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"eject": "expo eject",
"postinstall": "patch-package"
},
"dependencies": {
"#react-native-community/viewpager": "^4.1.6",
"#react-native-firebase/app": "^8.4.6",
"#unimodules/core": "^5.1.2",
"api-ecommerce": "^0.0.36",
"axios": "^0.18.0",
"babel-plugin-transform-decorators-legacy": "^1.3.5",
"babel-preset-env": "^1.7.0",
"base-64": "^0.1.0",
"by": "^0.2.3",
"create-react-context": "^0.2.3",
"css-select": "^3.1.0",
"currency-formatter": "^1.4.2",
"eslint": "^3.14.1",
"eslint-config-prettier": "^6.13.0",
"expo": "^39.0.0",
"expo-ads-admob": "~8.3.0",
"expo-ads-facebook": "~8.4.0",
"expo-analytics": "^1.0.8",
"expo-asset": "~8.2.0",
"expo-av": "~8.6.0",
"expo-constants": "~9.2.0",
"expo-facebook": "~9.0.0",
"expo-font": "~8.3.0",
"expo-google-app-auth": "^7.0.0",
"expo-google-sign-in": "~8.3.0",
"expo-linear-gradient": "~8.3.0",
"expo-localization": "~9.0.0",
"expo-web-browser": "~8.5.0",
"firebase": "^7.9.0-0",
"grpc": "^1.24.3",
"html-entities": "^1.2.1",
"lodash": "4.17.11",
"moment": "2.24.0",
"monet": "0.9.0",
"native-base": "^2.13.14",
"oauth-1.0a": "1.0.1",
"parse": "github:parse-community/Parse-SDK-JS#master",
"patch-package": "^6.1.2",
"path": "^0.12.7",
"postinstall-postinstall": "^2.0.0",
"react": "^16.14.0",
"react-dom": "^16.14.0",
"react-instantsearch": "^5.1.0",
"react-instantsearch-dom": "^5.7.0",
"react-native": "https://github.com/expo/react-native/archive/sdk-39.0.3.tar.gz",
"react-native-animatable": "1.3.2",
"react-native-app-intro-slider": "2.0.1",
"react-native-clean-form": "^0.5.0",
"react-native-collapsible": "1.4.0",
"react-native-country-picker-modal": "^0.7.1",
"react-native-credit-card-input": "^0.4.1",
"react-native-dev-menu": "^4.0.2",
"react-native-drawer": "git+https://github.com/luyx2412/react-native-drawer.git",
"react-native-expandable-section-flatlist": "^1.2.2",
"react-native-fluid-slider": "^1.0.2",
"react-native-gesture-handler": "~1.7.0",
"react-native-keyboard-aware-scroll-view": "^0.8.0",
"react-native-localization": "^2.1.6",
"react-native-masked-text": "1.11.1",
"react-native-modalbox": "1.7.1",
"react-native-paper": "2.15.0",
"react-native-parallax": "^0.3.0",
"react-native-radio-buttons": "^1.0.0",
"react-native-reanimated": "~1.13.0",
"react-native-render-html": "4.1.2",
"react-native-screens": "^2.11.0",
"react-native-scrollable-tab-view": "^1.0.0",
"react-native-side-menu": "^1.1.3",
"react-native-snap-carousel": "^3.6.0",
"react-native-star-rating": "^1.0.9",
"react-native-svg": "^5.5.1",
"react-native-svg-uri": "^1.2.3",
"react-native-swipe-list-view": "1.5.3",
"react-native-swiper": "^1.6.0-rc.3",
"react-native-web": "^0.13.18",
"react-native-windows": "^0.41.0",
"react-navigation": "^4.0.10",
"react-navigation-header-buttons": "2.2.0",
"react-navigation-props-mapper": "^0.4.0",
"react-navigation-stack": "^1.10.3",
"react-navigation-tabs": "^2.5.6",
"react-redux": "6.0.1",
"redux": "^4.0.0",
"redux-actions": "2.6.5",
"redux-persist": "^5.9.1",
"redux-thunk": "^2.3.0",
"required": "^1.0.0",
"reselect": "4.0.0",
"sentry-expo": "^2.0.1",
"styled-components": "^5.2.0",
"tcomb-form-native": "^0.6.13",
"urijs": "1.19.1",
"url": "^0.11.0",
"url-parse": "1.4.4",
"util": "0.11.1",
"uuid": "3.3.2",
"validate.js": "^0.12.0",
"wpapi": "^1.2.1"
},
"devDependencies": {
"babel-jest": "25.1.0",
"babel-plugin-transform-remove-console": "^6.9.4",
"babel-preset-expo": "^8.3.0",
"babel-preset-react-native": "4.0.1",
"jest": "25.1.0",
"reactotron-react-native": "3.2.1",
"reactotron-redux": "3.1.0"
},
"keywords": [
"ecommerce"
],
"license": "ISC"
}
I actually don't know why is this happening. I have some others warning like,
"Error: Warning: AsyncStorage has been extracted from react-native core and will be removed in a future release. It can now be installed and imported from"
I sharing my error log screenshot and package.json file below. Can anybody help me to get out?
{
"name": "eonbazar",
"displayName": "eonbazar",
"description": "MStore Pro - Complete React Native template for e-commerce",
"author": "InpireUI",
"version": "1.0.0",
"private": true,
"main": "node_modules/expo/AppEntry.js",
"scripts": {
"setup": "./scripts/setup.sh",
"start": "expo start",
"android": "expo start --android",
"ios": "expo start --ios",
"eject": "expo eject",
"postinstall": "patch-package"
},
"dependencies": {
"#callstack/react-theme-provider": "^2.1.0",
"#material-ui/core": "^4.11.0",
"#material-ui/icons": "^4.9.1",
"#material-ui/styles": "^4.10.0",
"#react-native-community/async-storage": "^1.12.1",
"#react-native-community/masked-view": "0.1.10",
"#react-native-community/viewpager": "4.1.6",
"#react-native-firebase/app": "^8.4.6",
"#unimodules/core": "^5.5.1",
"#unimodules/react-native-adapter": "~5.6.0",
"api-ecommerce": "^0.0.36",
"axios": "^0.20.0",
"babel-plugin-transform-decorators-legacy": "^1.3.5",
"babel-preset-env": "^1.7.0",
"base-64": "^1.0.0",
"by": "^0.2.3",
"core-js": "^3.6.5",
"create-react-context": "^0.3.0",
"css-select": "^3.1.0",
"currency-formatter": "^1.5.6",
"eslint": "^7.11.0",
"eslint-config-prettier": "^6.13.0",
"expo": "^39.0.3",
"expo-ads-admob": "~8.3.0",
"expo-ads-facebook": "~8.4.1",
"expo-analytics": "^1.0.16",
"expo-asset": "~8.2.0",
"expo-av": "~8.6.0",
"expo-constants": "~9.2.0",
"expo-facebook": "~9.0.0",
"expo-font": "~8.3.0",
"expo-google-app-auth": "^8.1.3",
"expo-google-sign-in": "~8.3.0",
"expo-linear-gradient": "~8.3.1",
"expo-localization": "~9.0.0",
"expo-web-browser": "~8.5.0",
"firebase": "7.24.0",
"grpc": "^1.24.3",
"html-entities": "^1.3.1",
"lodash": "^4.17.20",
"moment": "2.29.1",
"monet": "0.9.1",
"native-base": "^2.13.14",
"oauth-1.0a": "2.2.6",
"parse": "github:parse-community/Parse-SDK-JS#master",
"patch-package": "^6.2.2",
"path": "^0.12.7",
"postinstall-postinstall": "^2.1.0",
"prop-types": "^15.7.2",
"react": "^16.14.0",
"react-dom": "16.14.0",
"react-instantsearch": "^6.8.1",
"react-instantsearch-dom": "^6.8.1",
"react-native": "https://github.com/expo/react-native/archive/sdk-39.0.3.tar.gz",
"react-native-animatable": "1.3.3",
"react-native-app-intro-slider": "4.0.4",
"react-native-clean-form": "^0.5.0",
"react-native-collapsible": "1.5.3",
"react-native-confirmation-code-field": "^6.5.0",
"react-native-country-picker-modal": "^2.0.0",
"react-native-credit-card-input": "^0.4.1",
"react-native-dev-menu": "^4.0.2",
"react-native-drawer": "git+https://github.com/luyx2412/react-native-drawer.git",
"react-native-expandable-section-flatlist": "^1.2.2",
"react-native-fluid-slider": "^1.0.2",
"react-native-gesture-handler": "~1.8.0",
"react-native-keyboard-aware-scroll-view": "^0.9.3",
"react-native-keyboard-aware-scrollview": "^2.1.0",
"react-native-localization": "^2.1.6",
"react-native-masked-text": "1.13.0",
"react-native-modalbox": "2.0.2",
"react-native-paper": "4.2.0",
"react-native-parallax": "^0.3.0",
"react-native-radio-buttons": "^1.0.0",
"react-native-reanimated": "~1.13.1",
"react-native-render-html": "4.2.4",
"react-native-safe-area-view": "^1.1.1",
"react-native-screens": "~2.11.0",
"react-native-scrollable-tab-view": "^1.0.0",
"react-native-side-menu": "^1.1.3",
"react-native-snap-carousel": "^3.9.1",
"react-native-star-rating": "^1.1.0",
"react-native-swipe-list-view": "3.2.4",
"react-native-swiper": "^1.6.0",
"react-native-tab-view": "^2.15.2",
"react-native-web": "~0.14.2",
"react-native-webview": "^10.9.2",
"react-native-windows": "^0.63.5",
"react-navigation": "^4.4.2",
"react-navigation-header-buttons": "6.0.0",
"react-navigation-props-mapper": "^1.0.4",
"react-navigation-stack": "^2.8.4",
"react-navigation-tabs": "^2.9.2",
"react-proxy": "^1.1.8",
"react-redux": "7.2.1",
"reactotron-react-js": "^3.3.7",
"redux": "^4.0.5",
"redux-actions": "2.6.5",
"redux-persist": "^6.0.0",
"redux-thunk": "^2.3.0",
"required": "^1.0.0",
"reselect": "4.0.0",
"sentry-expo": "^3.0.2",
"styled-components": "^5.2.0",
"tcomb-form-native": "^0.6.20",
"urijs": "1.19.2",
"url": "^0.11.0",
"url-parse": "1.4.7",
"util": "0.12.3",
"uuid": "8.3.1",
"validate.js": "^0.13.1",
"wpapi": "^1.2.1"
},
"devDependencies": {
"#babel/types": "^7.12.1",
"babel-jest": "26.5.2",
"babel-plugin-transform-remove-console": "^6.9.4",
"babel-preset-expo": "^8.3.0",
"babel-preset-react-native": "4.0.1",
"jest": "26.5.3",
"reactotron-react-native": "5.0.0",
"reactotron-redux": "^3.1.3"
},
"keywords": [
"ecommerce"
],
"license": "ISC"
}
The error is misleading without more code or info, but I had a similar issue. Your problem may be the way withTheme is being imported #callstack/from react-theme-provider. Looking a the docs I had some success with changing the way I retrieved the function from the package. If you are importing it like this:
import { withTheme } from "#callstack/react-theme-provider";
Try instead to do the following:
import { createTheming } from '#callstack/react-theme-provider';
const { withTheme } = createTheming();
If you have a defaultTheme you can pass it as an argument like createTheming(defaultTheme);
I've updated react native to 0.59.5 and am getting this error:
bundling failed: TypeError: Cannot read property 'bindings' of null
at Scope.moveBindingTo (/Users/ben/vepo/frontend/node_modules/#babel/traverse/lib/scope/index.js:864:13)
at convertBlockScopedToVar (/Users/ben/vepo/frontend/node_modules/babel-plugin-transform-es2015-block-scoping/lib/index.js:139:13)
at PluginPass.VariableDeclaration (/Users/ben/vepo/frontend/node_modules/babel-plugin-transform-es2015-block-scoping/lib/index.js:26:9)
at newFn (/Users/ben/vepo/frontend/node_modules/#babel/traverse/lib/visitors.js:193:21)
at NodePath._call (/Users/ben/vepo/frontend/node_modules/#babel/traverse/lib/path/context.js:53:20)
at NodePath.call (/Users/ben/vepo/frontend/node_modules/#babel/traverse/lib/path/context.js:40:17)
at NodePath.visit (/Users/ben/vepo/frontend/node_modules/#babel/traverse/lib/path/context.js:88:12)
at TraversalContext.visitQueue (/Users/ben/vepo/frontend/node_modules/#babel/traverse/lib/context.js:118:16)
at TraversalContext.visitSingle (/Users/ben/vepo/frontend/node_modules/#babel/traverse/lib/context.js:90:19)
Ive seen solutions to upgrade babel-preset-react-native to 5.0.2. I've done that and it didn't work. Another solution was to use metro-react-native-babel-preset instead. That didn't work either. Another solution was to use #babel/preset-env. That didn't work either. I even commented out the code that the error is complaining about so I don't even know how it is giving the same error on that commented out line of code now...Any ideas?
package.json
{
"name": "vepo",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"rnpm": {
"assets": [
"./app/fonts"
]
},
"jest": {
"preset": "react-native",
"moduleNameMapper": {
"\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/__mocks__/fileMock.js",
"\\.(css|less)$": "<rootDir>/__mocks__/styleMock.js"
}
},
"dependencies": {
"#babel/core": "^7.4.3",
"#babel/preset-env": "^7.4.3",
"babel-preset-react-native": "5.0.2",
"flow-typed": "^2.4.0",
"generator-rn-toolbox": "^2.2.0",
"imagemagick": "^0.1.3",
"immutable": "4.0.0-rc.9",
"list": "^2.0.15",
"metro-bundler": "^0.22.1",
"metro-react-native-babel-preset": "^0.53.1",
"native-base": "^2.3.3",
"prop-types": "^15.5.10",
"react": "16.8.3",
"react-native": "0.59.5",
"react-native-aws3": "^0.0.8",
"react-native-blur": "^3.1.3",
"react-native-check-box": "^2.1.0",
"react-native-communications": "^2.2.1",
"react-native-drawer": "^2.3.0",
"react-native-easy-toast": "^1.2.0",
"react-native-elements": "^0.19.1",
"react-native-fbsdk": "^0.8.0",
"react-native-gesture-handler": "1.0.12",
"react-native-git-upgrade": "^0.2.7",
"react-native-image-picker": "^0.26.7",
"react-native-interactable": "0.1.2",
"react-native-mail": "^3.0.2",
"react-native-maps": "^0.16.4",
"react-native-modal": "^2.3.2",
"react-native-modalbox": "^1.3.9",
"react-native-multiple-choice": "^0.0.8",
"react-native-navigation": "^1.1.100",
"react-native-off-canvas-menu": "^0.1.31",
"react-native-optimized-flatlist": "^1.0.1",
"react-native-redux-router": "^1.0.7",
"react-native-root-toast": "^3.0.2",
"react-native-select-multiple": "^1.0.3",
"react-native-side-menu": "^0.20.1",
"react-native-vector-icons": "^5.0.0",
"react-navigation": "3.0.8",
"react-navigation-tabs": "^1.0.1",
"react-redux": "^5.0.3",
"redux": "^3.6.0",
"redux-immutable": "^4.0.0",
"redux-observable": "^0.14.1",
"redux-thunk": "^2.3.0",
"reselect": "^3.0.0",
"rxjs": "^5.2.0",
"yarn": "^1.3.2",
"yoga": "^0.0.0"
},
"devDependencies": {
"adm-zip": "^0.4.11",
"babel-cli": "^6.26.0",
"babel-eslint": "^7.1.1",
"babel-plugin-module-resolver": "^2.7.0",
"babel-preset-flow": "^6.23.0",
"eslint": "^3.17.0",
"eslint-config-prettier": "^2.9.0",
"eslint-plugin-flowtype": "^2.30.3",
"eslint-plugin-jsx": "^0.0.2",
"eslint-plugin-react": "^6.10.0",
"eslint-plugin-react-native": "^2.3.1",
"flow-bin": "^0.75.0",
"plist": "^2.1.0",
"react-devtools": "^3.2.1",
"react-test-renderer": "~15.4.1",
"redux-devtools": "^3.3.2",
"remote-redux-devtools": "^0.5.7",
"remotedev-server": "^0.2.4",
"xcode": "^1.0.0"
}
}
.babelrc
{
"presets": ["#babel/preset-env"]
}
When I restarted my computer it worked.
code that worked:
.babelrc
{
"presets": ["module:metro-react-native-babel-preset"]
}
package.json
{
"name": "vepo",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"rnpm": {
"assets": [
"./app/fonts"
]
},
"jest": {
"preset": "react-native",
"moduleNameMapper": {
"\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/__mocks__/fileMock.js",
"\\.(css|less)$": "<rootDir>/__mocks__/styleMock.js"
}
},
"dependencies": {
"#babel/core": "^7.4.3",
"#babel/preset-env": "^7.4.3",
"babel-preset-react-native": "5.0.2",
"flow-typed": "^2.4.0",
"generator-rn-toolbox": "^2.2.0",
"imagemagick": "^0.1.3",
"immutable": "4.0.0-rc.9",
"list": "^2.0.15",
"metro-bundler": "^0.22.1",
"metro-react-native-babel-preset": "^0.53.1",
"native-base": "2.12.1",
"prop-types": "^15.5.10",
"react": "16.8.3",
"react-native": "0.59.5",
"react-native-aws3": "^0.0.8",
"react-native-blur": "^3.1.3",
"react-native-check-box": "^2.1.0",
"react-native-communications": "^2.2.1",
"react-native-drawer": "^2.3.0",
"react-native-easy-toast": "^1.2.0",
"react-native-elements": "^0.19.1",
"react-native-fbsdk": "^0.8.0",
"react-native-gesture-handler": "1.0.12",
"react-native-git-upgrade": "^0.2.7",
"react-native-image-picker": "^0.26.7",
"react-native-interactable": "0.1.2",
"react-native-mail": "^3.0.2",
"react-native-maps": "^0.16.4",
"react-native-modal": "^2.3.2",
"react-native-modalbox": "^1.3.9",
"react-native-multiple-choice": "^0.0.8",
"react-native-navigation": "^1.1.100",
"react-native-off-canvas-menu": "^0.1.31",
"react-native-optimized-flatlist": "^1.0.1",
"react-native-redux-router": "^1.0.7",
"react-native-root-toast": "^3.0.2",
"react-native-select-multiple": "^1.0.3",
"react-native-side-menu": "^0.20.1",
"react-native-vector-icons": "^5.0.0",
"react-navigation": "3.0.8",
"react-navigation-tabs": "^1.0.1",
"react-redux": "^5.0.3",
"react-timer-mixin": "^0.13.4",
"redux": "^3.6.0",
"redux-immutable": "^4.0.0",
"redux-observable": "^0.14.1",
"redux-thunk": "^2.3.0",
"reselect": "^3.0.0",
"rxjs": "^5.2.0",
"yarn": "^1.3.2",
"yoga": "^0.0.0"
},
"devDependencies": {
"adm-zip": "^0.4.11",
"babel-cli": "^6.26.0",
"babel-eslint": "^7.1.1",
"babel-plugin-module-resolver": "^2.7.0",
"babel-preset-flow": "^6.23.0",
"eslint": "^3.17.0",
"eslint-config-prettier": "^2.9.0",
"eslint-plugin-flowtype": "^2.30.3",
"eslint-plugin-jsx": "^0.0.2",
"eslint-plugin-react": "^6.10.0",
"eslint-plugin-react-native": "^2.3.1",
"flow-bin": "^0.75.0",
"plist": "^2.1.0",
"react-devtools": "^3.2.1",
"react-test-renderer": "~15.4.1",
"redux-devtools": "^3.3.2",
"remote-redux-devtools": "^0.5.7",
"remotedev-server": "^0.2.4",
"xcode": "^1.0.0"
}
}
I'm getting this error:
The development server returned response 404. Cannot find entry file
index.js.
Here is my folder structure:
package.json
{
"name": "vepo",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "node node_modules/react-native/local-cli/cli.js start",
"test": "jest"
},
"rnpm": {
"assets": [
"./app/fonts"
]
},
"jest": {
"preset": "react-native",
"moduleNameMapper": {
"\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$": "<rootDir>/__mocks__/fileMock.js",
"\\.(css|less)$": "<rootDir>/__mocks__/styleMock.js"
}
},
"dependencies": {
"flow-typed": "^2.0.0",
"generator-rn-toolbox": "^2.2.0",
"imagemagick": "^0.1.3",
"immutable": "^3.8.1",
"native-base": "2.3.0",
"prop-types": "^15.5.10",
"react": "16.0.0",
"react-native": "0.50.3",
"react-native-aws3": "^0.0.8",
"react-native-blur": "^3.1.3",
"react-native-communications": "^2.2.1",
"react-native-drawer": "^2.3.0",
//"react-native-fbsdk": "git://github.com/facebook/react-native-fbsdk#065507aa1d2b8b0b6cb50d13117694123f8303fa",
"react-native-git-upgrade": "^0.2.7",
"react-native-image-picker": "^0.26.4",
"react-native-interactable": "^0.1.2",
"react-native-mail": "^3.0.2",
"react-native-maps": "^0.16.4",
"react-native-modal": "^2.3.2",
"react-native-modalbox": "^1.3.9",
"react-native-multiple-choice": "^0.0.8",
"react-native-navigation": "^1.1.100",
"react-native-off-canvas-menu": "^0.1.31",
"react-native-optimized-flatlist": "^1.0.1",
"react-native-redux-router": "^1.0.7",
"react-native-select-multiple": "^1.0.3",
"react-native-side-menu": "^0.20.1",
"react-native-vector-icons": "^4.4.0",
"react-navigation": "^1.0.0-beta.11",
"react-redux": "^5.0.3",
"redux": "^3.6.0",
"redux-immutable": "^4.0.0",
"redux-observable": "^0.14.1",
"reselect": "^3.0.0",
"rxjs": "^5.2.0",
"yoga": "^0.0.0"
},
"devDependencies": {
"babel-eslint": "^7.1.1",
"babel-jest": "19.0.0",
"babel-plugin-module-resolver": "^2.7.0",
"babel-preset-react-native": "3.0.1",
"eslint": "^3.17.0",
"eslint-plugin-flowtype": "^2.30.3",
"eslint-plugin-jsx": "^0.0.2",
"eslint-plugin-react": "^6.10.0",
"eslint-plugin-react-native": "^2.3.1",
"flow-bin": "^0.42.0",
"jest": "19.0.2",
"jest-cli": "^19.0.2",
"react-test-renderer": "~15.4.1",
"redux-devtools": "^3.3.2",
"remote-redux-devtools": "^0.5.7"
}
}
What am I doing wrong, to cause that error?
Create an index.js file in root directory of your project and copy your index.android.js or index.ios.js into it.
after RN 49 by default, we don't have different entries for ios and android. so we have just one index.js file that both android and ios use it.
I am getting a syntax error when running my react native app on iOS 10.2 iPhone 7 Plus simulator and iPhone 7 Plus physical device but not on iPhone 7. I have to idea where to begin looking for problem.
Here is my package.json file.
{
"name": "NativeProject",
"version": "0.0.1",
"private": true,
"scripts": {
"start": "webpack-dev-server --progress --colors --hot --inline --host 0.0.0.0 --port 3000",
"test": "jest",
"build": "webpack -p"
},
"rnpm": {
"assets": [
"fonts"
]
},
"jest": {
"preset": "jest-react-native",
"globals": {
"__DEV__": true
}
},
"dependencies": {
"babel-cli": "^6.22.2",
"babel-core": "^6.22.1",
"babel-jest": "^18.0.0",
"babel-loader": "^6.2.4",
"babel-polyfill": "^6.22.0",
"babel-preset-es2015": "^6.22.0",
"babel-preset-react": "^6.22.0",
"babel-preset-react-native": "^1.9.1",
"babel-preset-stage-2": "^6.22.0",
"classnames": "^2.2.5",
"crypto-js": "^3.1.9-1",
"css-loader": "^0.26.1",
"express": "^4.14.1",
"extract-text-webpack-plugin": "^1.0.1",
"file-loader": "^0.10.0",
"firebase": "^3.6.8",
"font-awesome": "^4.7.0",
"html-webpack-plugin": "^2.28.0",
"jest": "^18.0.0",
"jest-react-native": "^18.0.0",
"json-loader": "^0.5.4",
"moment": "^2.17.1",
"postcss": "^5.2.11",
"postcss-cssnext": "^2.9.0",
"postcss-import": "^9.0.0",
"postcss-loader": "^1.2.1",
"react": "^15.4.2",
"react-addons-css-transition-group": "^15.4.1",
"react-dom": "^15.4.1",
"react-native": "^0.41.1",
"react-native-calendar": "^0.10.0",
"react-native-calendar-picker": "^3.0.0",,
"react-native-cli": "^2.0.1",
"react-native-fbsdk": "^0.5.0",
"react-native-google-places-autocomplete": "^1.2.7",
"react-native-sglistview": "^0.3.2",
"react-native-swipeout": "git+https://github.com/magrinj/react-native-swipeout.git",
"react-native-vector-icons": "^4.0.0",
"react-native-video": "1.0.0",
"react-redux": "^5.0.2",
"react-router": "^3.0.2",
"react-test-renderer": "^15.4.1",
"redux": "^3.6.0",
"redux-logger": "^2.8.1",
"redux-mock-store": "^1.2.2",
"redux-thunk": "^2.2.0",
"reselect": "^2.5.4",
"style-loader": "^0.13.1",
"url-loader": "^0.5.7",
"webpack": "^2.2.1",
"webpack-dev-server": "^2.3.0"
},
"devDependencies": {
"extract-text-webpack-plugin": "^2.0.0-rc.3"
}
}