webpack-dev-middleware
webpack-dev-middleware copied to clipboard
DllReferencePlugin fails when using webpack-dev-server
Do you want to request a feature or report a bug?
report a bug
What is the current behavior?
When using DllReferencePlugin with webpack-dev-server or webpack-dev-middleware, it will occurs an error:
Error: ENOENT: no such file or directory, open '/path/to/js/manifest.json'
at Error (native)
If the current behavior is a bug, please provide the steps to reproduce.
const webpack = require('webpack');
const WebpackDevServer = require('webpack-dev-server');
const config = require('./webpack.config');
const compiler = webpack(config);
const server = new WebpackDevServer(compiler, {});
server.listen(8080, '127.0.0.1', () => {
console.log('Starting server on http://localhost:' + 8080);
});
and the webpack.config
is just from this project's example directory, https://github.com/webpack/webpack/blob/master/examples/explicit-vendor-chunk/webpack.config.js
What is the expected behavior?
run correctly like the code below:
const webpack = require('webpack');
const config = require('./webpack.config');
webpack(config, (err, stats) => {
process.stdout.write(stats.toString() + "\n");
}); // this runs ok
Please mention other relevant information such as the browser version, Node.js version, webpack version and Operating System.
node version: 6.9.0 webpack version: 3.8.1
yep, sorry that's not implemented yet.
The problem is that the file is written into the in-memory filesystem, but the other compilation tries to read it from the real filesystem. Maybe we need to overlay the in-memory filesystem on top of the input filesystem.
@sokra is any solution/workaround for that? I'm having the same problem but when i'm trying to build the production build.
@jetpack3331 no, you can send a PR
This issue had no activity for at least three months.
It's subject to automatic issue closing if there is no activity in the next 15 days.
bump
Issue was closed because of inactivity.
If you think this is still a valid issue, please file a new issue with additional information.
I think it can be solved using writeFiles
, but let's add tests for this case, keep open
Same problem - https://github.com/webpack/webpack-dev-middleware/issues/861
Fixed in webpack v5, we split fs
into to things inputFileSystem
and outputFileSystem
, so no problem anymore