Skip to content

Commit 01b9d33

Browse files
committed
docs(config) improve documentation about [contenthash]
1 parent 7002fa1 commit 01b9d33

File tree

1 file changed

+9
-8
lines changed

1 file changed

+9
-8
lines changed

src/content/configuration/output.md

+9-8
Original file line numberDiff line numberDiff line change
@@ -319,14 +319,15 @@ Note this option does not affect output files for on-demand-loaded chunks. For t
319319

320320
The following substitutions are available in template strings (via webpack's internal [`TemplatedPathPlugin`](https://github.com/webpack/webpack/blob/master/lib/TemplatedPathPlugin.js)):
321321

322-
| Template | Description |
323-
| ----------- | ----------------------------------------------------------------------------------- |
324-
| [hash] | The hash of the module identifier |
325-
| [chunkhash] | The hash of the chunk content |
326-
| [name] | The module name |
327-
| [id] | The module identifier |
328-
| [query] | The module query, i.e., the string following `?` in the filename |
329-
| [function] | The function, which can return filename [string] |
322+
| Template | Description |
323+
| ------------- | ----------------------------------------------------------------------------------- |
324+
| [hash] | The hash of the module identifier |
325+
| [contenthash] | the hash of the content of a file, which is different for each asset |
326+
| [chunkhash] | The hash of the chunk content |
327+
| [name] | The module name |
328+
| [id] | The module identifier |
329+
| [query] | The module query, i.e., the string following `?` in the filename |
330+
| [function] | The function, which can return filename [string] |
330331

331332
The lengths of `[hash]` and `[chunkhash]` can be specified using `[hash:16]` (defaults to 20). Alternatively, specify [`output.hashDigestLength`](#outputhashdigestlength) to configure the length globally.
332333

0 commit comments

Comments
 (0)