Angular - Prod Build not generating unique hashes
There are plenty of other people that face the same issue with you. Check Here.
I don't think you'll find a solution to your problem if there isn't one on the official angular cli github, but based on the replies, can you please try updating your congifuration with the following and let me know if it works?
"configurations": {
"production": {
"fileReplacements": [
{
"replace": "src/environments/environment.ts",
"with": "src/environments/environment.prod.ts"
}
],
"optimization": true,
"outputHashing": "all",
"sourceMap": false,
"extractCss": true,
"namedChunks": false,
"aot": true,
"extractLicenses": true,
"vendorChunk": false,
"buildOptimizer": true
}
}
Edit: Expected files to change
Your actual code is only in main.js (which I can see gets a new hash). The rest of the files will seldom change. Check what the files mean here
main.js contains all our code including components (ts, html and css codes), pipes, directives, services and all other imported modules (including third party).
scripts.js contains the scripts we declare in the scripts section of angular.json file
"scripts": [
"myScript.js",
]