Skip to content
This repository has been archived by the owner on Jan 13, 2023. It is now read-only.

Commit

Permalink
Since RN bumped the babel version to 7 we have to add a couple of plu…
Browse files Browse the repository at this point in the history
…gins to handle some of the code in the boilerplate.

Almost all dependencies are bumped except for the mobx deps (because of limitations in Android).
We need to handle the jest setup, for know I just got it tow work. We probably need to update the jest-preset-ignite config.
  • Loading branch information
nirre7 committed Sep 25, 2018
1 parent a55a6ac commit b64e214
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 24 deletions.
11 changes: 10 additions & 1 deletion boilerplate/.babelrc
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"presets": ["react-native"],
"presets": ["module:metro-react-native-babel-preset"],
"env": {
"production": {
}
Expand All @@ -10,6 +10,15 @@
{
"include": ["NODE_ENV", "API"]
}
],
[
"@babel/plugin-proposal-decorators",
{
"legacy": true
}
],
[
"@babel/plugin-proposal-optional-catch-binding"
]
]
}
64 changes: 41 additions & 23 deletions boilerplate/package.json.ejs
Original file line number Diff line number Diff line change
Expand Up @@ -20,53 +20,71 @@
"storybook": "storybook start -p 9001 --skip-packager"
},
"dependencies": {
"apisauce": "0.14.3",
"apisauce": "0.16.0",
"lodash.throttle": "4.1.1",
"mobx": "4.2.1",
"mobx-react": "5.1.2",
"mobx-state-tree": "2.0.5",
"ramda": "0.25.0",
"react-native-i18n": "2.0.12",
"react-native-keychain": "3.0.0-rc.3",
"react-native-splash-screen": "3.0.6",
"react-navigation": "2.3.1",
"reactotron-mst": "2.1.0",
"reactotron-react-native": "2.1.0",
"react-native-i18n": "2.0.15",
"react-native-keychain": "3.0.0",
"react-native-splash-screen": "3.1.1",
"react-navigation": "2.12.1",
"reactotron-mst": "^2.1.0",
"reactotron-react-native": "^2.1.0",
"validate.js": "0.12.0"
},
"devDependencies": {
"@babel/plugin-proposal-decorators": "^7.0.0",
"@babel/plugin-proposal-optional-catch-binding": "^7.0.0",
"@storybook/addon-storyshots": "github:infinitered/addon-storyshots",
"@storybook/react-native": "3.4.3",
"@types/jest": "22.2.3",
"@types/jest": "23.3.1",
"@types/ramda": "0.25.28",
"@types/react": "16.0.40",
"@types/react-native": "0.55.12",
"@types/react-navigation": "2.0.6",
"@types/react": "16.4.14",
"@types/react-native": "^0.56.19",
"@types/react-navigation": "2.0.17",
"@types/react-test-renderer": "16.0.1",
"@types/validate.js": "0.11.0",
"babel-plugin-transform-inline-environment-variables": "0.4.1",
"babel-plugin-transform-inline-environment-variables": "0.4.3",
"metro-react-native-babel-preset": "0.45.2",
"jest-preset-ignite": "0.5.0",
"npm-run-all": "4.1.3",
"patch-package": "5.1.1",
"postinstall-prepare": "1.0.1",
"prettier": "1.12.1",
"react-dom": "16.2.0",
"react-native-typescript-transformer": "1.2.5",
"react-dom": "16.5.0",
"react-native-typescript-transformer": "1.2.10",
"react-powerplug": "0.1.5",
"react-test-renderer": "16.3.1",
"react-test-renderer": "16.4.1",
"rimraf": "2.6.2",
"solidarity": "2.1.0",
"tslint": "5.10.0",
"tslint-config-prettier": "1.12.0",
"typescript": "2.8.3"
"tslint": "5.11.0",
"tslint-config-prettier": "1.15.0",
"typescript": "2.9.2"
},
"jest": {
"preset": "jest-preset-ignite",
"testPathIgnorePatterns": [
"/node_modules"
"preset": "react-native",
"transform": {
"^.+\\.(ts|tsx)$": "<rootDir>/node_modules/jest-preset-ignite/preprocessor.js",
"^.+\\.js$": "<rootDir>/node_modules/react-native/jest/preprocessor.js"
},
"testMatch": [
"**/__tests__/**/*.js?(x)",
"**/?(*.)(spec|test).js?(x)",
"**/__tests__/**/*.ts?(x)",
"**/?(*.)(spec|test).ts?(x)"
],
"globals": {
"__TEST__": true
"moduleFileExtensions": [
"js",
"jsx",
"ts",
"tsx",
"json"
],
"moduleNameMapper": {
"^[./a-zA-Z0-9$_-]+\\.(bmp|gif|jpg|jpeg|png|psd|svg|webp|ttf|otf)$": "RelativeImageStub",
"^React$": "<rootDir>/node_modules/react"
}
},
"rnpm": {
Expand Down

0 comments on commit b64e214

Please sign in to comment.