Compare commits

..
3 Commits
Author SHA1 Message Date
Emin Khateeb ec3a826edc Update README.md
added new solution for debugging
2018-06-06 17:28:42 +02:00
Emin Khateeb a585faa237 Update tsconfig.json
re-ordered members alphabetically and added module option
2018-06-06 17:09:01 +02:00
Emin Khateeb 919ebb922e Update setup.js
removed start script config parameter as it seems to work just fine without
2018-06-06 17:05:20 +02:00
3 changed files with 29 additions and 11 deletions

No files matched your search

+21 -1
View File
@@ -45,7 +45,27 @@ The React Native CLI will do everything just as without a template and afterward
### Does debugging work too?
Yes it does. Some users reported that they got an error about relative paths when they tried to debug inside Visual Studio Code. In this case check out the [fix by Mo Mac](https://medium.com/@nocnoc/great-work-f0b5ef365ca6).
Yes it does, but you need to enable the `sourceMap` option in the `tsconfig.json`.
Make sure it looks something like this:
```json
{
"compilerOptions": {
"allowSyntheticDefaultImports": true,
"esModuleInterop": true,
"jsx": "react",
"module": "es6",
"moduleResolution": "node",
"noEmit": true,
"noImplicitAny": true,
"target": "es6",
"sourceMap": true
},
"exclude": ["node_modules"]
}
```
This is not enabled by default as it is unknown if it has any negative effects on the transpilation time. For more information make sure to check out the [post by Nicolas Hémonic](https://medium.com/@NicolasHemonic/hi-mo-mac-d18286202602).
## :globe_with_meridians: Links
-1
View File
@@ -30,7 +30,6 @@ const execOptions = {stdio: 'inherit'}
console.log('🔄 Please wait...\n')
packageJson.scripts.start = `${packageJson.scripts.start} --config ../../../../rn-cli.config.js`
packageJson.jest = Object.assign(packageJson.jest, jestConfig)
writeFile('package.json', JSON.stringify(packageJson, null, 2))
+8 -9
View File
@@ -1,14 +1,13 @@
{
"compilerOptions": {
"target": "es2015",
"jsx": "react",
"noEmit": true,
"moduleResolution": "node",
"noImplicitAny": true,
"allowSyntheticDefaultImports": true,
"esModuleInterop": true
"esModuleInterop": true,
"jsx": "react",
"module": "es6",
"moduleResolution": "node",
"noEmit": true,
"noImplicitAny": true,
"target": "es6"
},
"exclude": [
"node_modules"
]
"exclude": ["node_modules"]
}