I cannot start dev server via npm start, I get the following error, in version 0.21.5:
Failed to compile with 1 error.
ERROR in ./demo/src/index.js
Module parse failed: Unexpected token (8:11)
You may need an appropriate loader to handle this file type.
| class Demo extends Component {
| render() {
| return <div>
| <h1>NWB Demo</h1>
| <Example/>
@ multi C:/Users/u0078867/AppData/Roaming/npm/node_modules/nwb/polyfills.js (we
bpack)-dev-server/client?/ (webpack)/hot/only-dev-server.js ./demo/src/index.js
Same for older versions.
I am also getting the same error while building and testing. Here and example while building;
C:\Users\u0078867\Desktop\KULeuvenJob\my_node_modules\NWB>npm run build
> NWB@1.0.0 build C:\Users\u0078867\Desktop\KULeuvenJob\my_node_modules\NWB
> nwb build-react-component
V Cleaning module
V Creating ES5 build
V Creating ES6 modules build
V Cleaning demo
× Building demo
Failed to compile with 1 error.
ERROR in ./demo/src/index.js
Module parse failed: Unexpected token (8:11)
You may need an appropriate loader to handle this file type.
| class Demo extends Component {
| render() {
| return <div>
| <h1>NWB Demo</h1>
| <Example/>
@ multi C:/Users/u0078867/AppData/Roaming/npm/node_modules/nwb/polyfills.js ./d
emo/src/index.js
Error running command: Build failed with errors.
Error: Build failed with errors.
at C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\lib\webpackBuild.j
s:76:17
at emitRecords.err (C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\n
ode_modules\webpack\lib\Compiler.js:265:13)
at Compiler.emitRecords (C:\Users\u0078867\AppData\Roaming\npm\node_modules\
nwb\node_modules\webpack\lib\Compiler.js:371:38)
at emitAssets.err (C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\no
de_modules\webpack\lib\Compiler.js:258:10)
at applyPluginsAsyncSeries1.err (C:\Users\u0078867\AppData\Roaming\npm\node_
modules\nwb\node_modules\webpack\lib\Compiler.js:364:12)
at next (C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\node_modules
\tapable\lib\Tapable.js:218:11)
at Compiler.compiler.plugin (C:\Users\u0078867\AppData\Roaming\npm\node_modu
les\nwb\node_modules\webpack\lib\performance\SizeLimitsPlugin.js:99:4)
at Compiler.applyPluginsAsyncSeries1 (C:\Users\u0078867\AppData\Roaming\npm\
node_modules\nwb\node_modules\tapable\lib\Tapable.js:222:13)
at Compiler.afterEmit (C:\Users\u0078867\AppData\Roaming\npm\node_modules\nw
b\node_modules\webpack\lib\Compiler.js:361:9)
at require.forEach.err (C:\Users\u0078867\AppData\Roaming\npm\node_modules\n
wb\node_modules\webpack\lib\Compiler.js:350:15)
at C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\node_modules\async
\dist\async.js:473:16
at iteratorCallback (C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\
node_modules\async\dist\async.js:1050:13)
at C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\node_modules\async
\dist\async.js:958:16
at C:\Users\u0078867\AppData\Roaming\npm\node_modules\nwb\node_modules\grace
ful-fs\graceful-fs.js:43:10
at FSReqWrap.oncomplete (fs.js:123:15)
npm ERR! Windows_NT 6.1.7601
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\u0078867\\AppDat
a\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "run" "build"
npm ERR! node v6.9.4
npm ERR! npm v3.8.9
npm ERR! code ELIFECYCLE
npm ERR! NWB@1.0.0 build: `nwb build-react-component`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the NWB@1.0.0 build script 'nwb build-react-component'.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the NWB package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! nwb build-react-component
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs NWB
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls NWB
npm ERR! There is likely additional logging output above.
npm ERR! Please include the following file with any support request:
npm ERR! C:\Users\u0078867\Desktop\KULeuvenJob\my_node_modules\NWB\npm-debug
.log
Component seems to get built properly, but whenever it is matter to build the demo or to test, sale problem occurs.
This issue is a:
Hi,
I cannot start dev server via
npm start
, I get the following error, in version 0.21.5:Same for older versions.
I am also getting the same error while building and testing. Here and example while building;
Component seems to get built properly, but whenever it is matter to build the demo or to test, sale problem occurs.
Adding:
to
nwb.config.js
does not solve the problem.Any idea?
Thanks