webpack-dev-server is telling me:
Invalid configuration object. webpack-dev-server has been initialised using a configuration object that does not match the API schema.
- configuration has an unknown property 'outputPath'. These properties are valid:
object { hot?, hotOnly?, lazy?, host?, filename?, publicPath?, port?, socket?, watchOptions?, headers?, clientLogLevel?, key?, cert?, ca?, pfx?, pfxPassphrase?, inline?, public?, https?, contentBase?, watchContentBase?, open?, features?, compress?, proxy?, historyApiF
allback?, staticOptions?, setup?, stats?, reporter?, noInfo?, quiet?, serverSideRender?, index?, log?, warn? }
webpack works fine and generates everything well.
These are my config files:
webpack and webpack-dev-server version:
webpack: 1.10.x/2.x
webpack-dev-server: 1.x/2.x
Please tell us about your environment:
Windows 10
outputPath isn't a valid option in webpack-dev-server, it doesn't do anything. So you can remove outputPath in the devServer object.
Now it's telling me:
# webpack-dev-server --config config/webpack.dev.js --progress --profile --content-base src/ 10% building modules 3/3 modules 0 active
Project is running at http://localhost:3000/
webpack output is served from /
Content not from webpack is served from D:\projects\living\user-platform\project\src
404s will fallback to /index.html 9304ms building modules 4ms add1m150ms 226ms asset82ms emitting
[default] Checking started in a separate process...
events.js:160
throw er; // Unhandled 'error' event
^
Error: This socket is closed
at WriteStream.Socket._writeGeneric (net.js:683:19)
at WriteStream.Socket._write (net.js:734:8)
at doWrite (_stream_writable.js:334:12)
at writeOrBuffer (_stream_writable.js:320:5)
at WriteStream.Writable.write (_stream_writable.js:247:11)
at WriteStream.Socket.write (net.js:661:40)
at Console.warn (console.js:51:16)
at printErrorAndExit (D:\projects\living\user-platform\project\node_modules\source-map-support\source-map-support.js:406:11)
at process.emit (D:\projects\living\user-platform\project\node_modules\source-map-support\source-map-support.js:419:16)
at process._fatalException (bootstrap_node.js:292:26)
You seem to be using the package source-map-support. Could you temporarily disable it and see if that resolves it? It's not a package webpack installs, and I can't reproduce this on my Windows machine.
Thanks @SpaceK33z . I'm not able to find out what I need to comment.
Which line do I need to comment?
I've tried to comment devtool: 'cheap-module-source-map' on my webpack.dev.js. However, the message is the same.
@jeusdi, I also don't know where it is, but the stack trace you posted doesn't seem to come from anything that is installed by webpack or webpack-dev-server. I'd suggest to remove some plugins / loaders to narrow down the issue.
Mmm, I've asked it on this question on stackoverflow. What do you think about that?
I'm going to close this and put a clear warning in the README that webpack-dev-server has issues with Node.js v7.
configuration has an unknown property 'modules'.
React 2.5.1 and followed all advice, documentation is useless. Any help?
@stevematdavies please try Stack Overflow or the webpack Gitter for support.