{"id":16489074,"url":"https://github.com/thundernet8/webpackhashtest","last_synced_at":"2025-09-01T07:34:52.093Z","repository":{"id":79658623,"uuid":"96615916","full_name":"thundernet8/WebpackHashTest","owner":"thundernet8","description":null,"archived":false,"fork":false,"pushed_at":"2017-07-11T05:31:56.000Z","size":62,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-01T04:24:55.221Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://github.com/thundernet8/Blog/issues/2","language":"JavaScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/thundernet8.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-07-08T11:52:04.000Z","updated_at":"2017-07-11T05:32:18.000Z","dependencies_parsed_at":"2023-05-14T07:15:41.326Z","dependency_job_id":null,"html_url":"https://github.com/thundernet8/WebpackHashTest","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/thundernet8/WebpackHashTest","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thundernet8%2FWebpackHashTest","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thundernet8%2FWebpackHashTest/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thundernet8%2FWebpackHashTest/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thundernet8%2FWebpackHashTest/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/thundernet8","download_url":"https://codeload.github.com/thundernet8/WebpackHashTest/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/thundernet8%2FWebpackHashTest/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":273088831,"owners_count":25043574,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-09-01T02:00:09.058Z","response_time":120,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-11T13:42:58.598Z","updated_at":"2025-09-01T07:34:52.059Z","avatar_url":"https://github.com/thundernet8.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"## WebpackHashTest\n\n[Post About this](https://github.com/thundernet8/Blog/issues/2)\n\n## More\n\nThe official hashmoduleidsplugin could keep chunhash stable via using hash module id rather than number id, but it does not change the entry chunks specified in config.entry to have a hash id, and sometimes the entry chunk order may change without a config.entry change which lead to a chunkhash change.\n\nSo I write a webpack plugin [WebpackStableChunkId](https://www.npmjs.com/package/webpackstablechunkid)to solve this, clilk[this](./webpack.config.babel.js) to find the usage.\n\nwebpack自带的hashmoduleidsplugin插件通过将模块的id以引用路径的hash特征值表示，以稳定chunkhash，但是config.entry中指定的chunks仍然使用了数字id，而且有些时候尽管config.entry未改变，这些entry chunks的排序会变化，导致chunk id变化，则chunkhash在代码内容未更改的情况意外更新了。\n\n因此我写了一个webpack插件[WebpackStableChunkId](https://www.npmjs.com/package/webpackstablechunkid)来解决这个问题，查看[示例](./webpack.config.babel.js)。\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthundernet8%2Fwebpackhashtest","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fthundernet8%2Fwebpackhashtest","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fthundernet8%2Fwebpackhashtest/lists"}