-
-
Notifications
You must be signed in to change notification settings - Fork 1.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Webpack dev server and [hash] file names #438
Labels
Comments
There is no need to use hash in webpack dev server, there is no cache problems. |
It does work in webpack-dev-server, but it is not recommended. If you do this, on every incremental build the server will generate a new JS file with the hash in it. The old files will not be removed, so the process will slowly run out of memory. I'm using this hack in my config: const IS_DEV_SERVER = process.argv[1].indexOf('webpack-dev-server') >= 0;
module.exports = {
output: {
filename: `[name]-${IS_DEV_SERVER ? 'dev' : '[hash:7]'}.js`,
},
}; |
khalwat
added a commit
to nystudio107/annotated-webpack-config
that referenced
this issue
Aug 13, 2020
…webpack/webpack-dev-server#438) Signed-off-by: Andrew Welch <[email protected]>
Bcdo
added a commit
to Bcdo/project
that referenced
this issue
Aug 14, 2020
- Added `--no-tablespaces` to the mysqldump command options to work around changes in MySQL Fixed - Modern config only for local dev, [fixing multi-compiler issues](webpack/webpack-dev-server#2355) with HRM - Fix redis session config to use `App::sessionConfig()` Changed - Remove `[hash]` from dev config to eliminate potential [memory errors](webpack/webpack-dev-server#438) - Use `[contenthash]` in production instead of [hash or chunkhash](webpack/webpack.js.org#2096) - Readme file to give proper credit - - -
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Does webpack-dev-server supports bundle names with [hash] in file name?
I have the following setup:
All assets generated correctly, but how can I reference it in my index.html? Js or css file name depends on [hash] value and changes with every build.
The text was updated successfully, but these errors were encountered: