mirror of
https://github.com/zhigang1992/react-native.git
synced 2026-04-29 04:35:36 +08:00
[ReactNative] Revert packager ignoring node_modules
This commit is contained in:
committed by
Spencer Ahrens
parent
6aea50d6f8
commit
8d6d0ec4a4
@@ -60,7 +60,7 @@
|
|||||||
"react-timer-mixin": "^0.13.1",
|
"react-timer-mixin": "^0.13.1",
|
||||||
"react-tools": "0.13.2",
|
"react-tools": "0.13.2",
|
||||||
"rebound": "^0.0.12",
|
"rebound": "^0.0.12",
|
||||||
"sane": "tadeuzagallo/sane#a029f8b04a",
|
"sane": "^1.1.2",
|
||||||
"source-map": "0.1.31",
|
"source-map": "0.1.31",
|
||||||
"stacktrace-parser": "frantic/stacktrace-parser#493c5e5638",
|
"stacktrace-parser": "frantic/stacktrace-parser#493c5e5638",
|
||||||
"uglify-js": "~2.4.16",
|
"uglify-js": "~2.4.16",
|
||||||
|
|||||||
@@ -53,6 +53,9 @@ var options = parseCommandLine([{
|
|||||||
}, {
|
}, {
|
||||||
command: 'skipflow',
|
command: 'skipflow',
|
||||||
description: 'Disable flow checks'
|
description: 'Disable flow checks'
|
||||||
|
}, {
|
||||||
|
command: 'nonPersistent',
|
||||||
|
description: 'Disable file watcher'
|
||||||
}]);
|
}]);
|
||||||
|
|
||||||
if (options.projectRoots) {
|
if (options.projectRoots) {
|
||||||
@@ -199,6 +202,7 @@ function statusPageMiddleware(req, res, next) {
|
|||||||
|
|
||||||
function getAppMiddleware(options) {
|
function getAppMiddleware(options) {
|
||||||
return ReactPackager.middleware({
|
return ReactPackager.middleware({
|
||||||
|
nonPersistent: options.nonPersistent,
|
||||||
projectRoots: options.projectRoots,
|
projectRoots: options.projectRoots,
|
||||||
blacklistRE: blacklist(options.platform),
|
blacklistRE: blacklist(options.platform),
|
||||||
cacheVersion: '2',
|
cacheVersion: '2',
|
||||||
|
|||||||
@@ -67,7 +67,6 @@ function createWatcher(rootConfig) {
|
|||||||
var watcher = new Watcher(rootConfig.dir, {
|
var watcher = new Watcher(rootConfig.dir, {
|
||||||
glob: rootConfig.globs,
|
glob: rootConfig.globs,
|
||||||
dot: false,
|
dot: false,
|
||||||
ignore: '**/node_modules/**/*',
|
|
||||||
});
|
});
|
||||||
|
|
||||||
return new Promise(function(resolve, reject) {
|
return new Promise(function(resolve, reject) {
|
||||||
|
|||||||
Reference in New Issue
Block a user