angular - process is not defined in lite-server with redux -
when using default systemjs config angular 2 rc.5, lite-server throw error of process not defined if add redux dependency. has experienced this? here trace stack:
 (index):43 error: referenceerror: process not defined         @ object.eval (http://localhost:3000/node_modules/redux/lib/index.js:38:5)         @ eval (http://localhost:3000/node_modules/redux/lib/index.js:47:4)         @ eval (http://localhost:3000/node_modules/redux/lib/index.js:48:3)         @ object.eval (http://localhost:3000/node_modules/ng2-redux/lib/components/ng-redux.js:14:15)     evaluating http://localhost:3000/node_modules/redux/lib/index.js     evaluating http://localhost:3000/node_modules/ng2-redux/lib/components/ng-redux.js     evaluating http://localhost:3000/node_modules/ng2-redux/lib/index.js     evaluating http://localhost:3000/actions/session.actions.js     evaluating http://localhost:3000/app/app.component.js     evaluating http://localhost:3000/app/app.module.js     evaluating http://localhost:3000/app/main.js     error loading http://localhost:3000/app/main.js 
for stack overflow record, repeating response same question on github: https://github.com/angular-redux/ng2-redux/issues/202
try putting in system.config.js:
var map = {   /* ... */   'ng2-redux': 'node_modules/ng2-redux',   'redux':     'node_modules/redux', };  var packages = {   /* ... */   'ng2-redux': { main: 'lib/index.js', defaultextension: 'js' },   'redux':     { main: 'dist/redux.js', defaultextension: 'js' }, };      
Comments
Post a Comment