rehash-webpack-plugin:webpack5 中最终发出的资产的真实 contenthash

时间:2024-08-13 06:02:20
【文件属性】:

文件名称:rehash-webpack-plugin:webpack5 中最终发出的资产的真实 contenthash

文件大小:8KB

文件格式:ZIP

更新时间:2024-08-13 06:02:20

JavaScript

REHASH Webpack 插件 webpack5 中发出的资产的真实内容哈希。 安装 网络包 5 npm i -D rehash-webpack-plugin yarn add --dev rehash-webpack-plugin 然后,您可以使用其 md5 值轻松重命名发出的 JS/CSS 文件。 用法 该插件将根据最终 webpack 发出的资产内容计算哈希值,替换 JS/CSS 文件名中的 contenthash 或 chunkhash。 只需按照以下步骤操作: 将插件添加到你的webpack 检查并适当修改你的webpack配置文件根据生产环境是否导出sourcemap文件,推荐两种设置方式。 devtool 设置为 none 的source-map 、 nosources-source-map 、 hidden-nosources-source-map 、 h


【文件预览】:
rehash-webpack-plugin-master
----.babelrc(267B)
----index.js(205B)
----package.json(829B)
----src()
--------index.js(8KB)
----.npmignore(470B)
----.gitignore(2KB)
----README.md(3KB)
----.gitattributes(243B)

网友评论