erikras / erikras/react-redux-universal-hot-example
Webpack [hash] differs on different computers
- Dominant language
- JavaScript
- Stars
- 12.1k
- Forks
- 2.5k
- PR merge metrics
- No merged PRs in 30d
Description
Once I run npm run build on different computers I'm getting different hash, because source map loader is generating js files depending on hash name used for source map files:

Lets disable source map using setting `devtool` to null (`devtool: null`):

Now you can see the files are all the same, but the hash generated differently on different computers.
Because we have multiple application servers which are response through load-balancer, and we are not sending our assets to any CDN, we are getting into a trouble, because assets names are not the same.
- Any ideas why is that happen?
- How do the webpack generates `[hash]`?
Contributor guide
Research direction
Start by running npm run build on the different computers described in the report and compare the generated asset names with source maps enabled and with devtool set to null. Read the webpack configuration and webpack's [hash] behavior; done means identifying the source of the differing hashes and establishing reproducible asset names across builds.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript, webpack
- Domain
- build-system
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100