Skip to content

Commit 903237a

Browse files
authored
docs(configuration): add note for output.chunkFilename (#7335)
1 parent 8e94eb9 commit 903237a

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/content/configuration/output.mdx

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,6 +169,8 @@ module.exports = {
169169
};
170170
```
171171

172+
T> If the `output.filename` is defined as a string contiaining placeholder such as `[name]`, `[id]`, [`contenthash`], or [`chunkhash`], the default value for `output.chunkFilename` will be derived from the `output.filename`. Otherwise, `[id].js` will be used as the default value.
173+
172174
## output.chunkFormat
173175

174176
`false` `string: 'array-push' | 'commonjs' | 'module' | <any string>`
@@ -600,7 +602,7 @@ Make sure to read the [Caching guide](/guides/caching) for details. There are mo
600602

601603
Note this option is called filename but you are still allowed to use something like `'js/[name]/bundle.js'` to create a folder structure.
602604

603-
Note this option does not affect output files for on-demand-loaded chunks. It only affects output files that are initially loaded. For on-demand-loaded chunk files, the [`output.chunkFilename`](#outputchunkfilename) option is used. Files created by loaders also aren't affected. In this case, you would have to try the specific loader's available options.
605+
T> Note this option does not affect output files for on-demand-loaded chunks. It only affects output files that are initially loaded. For on-demand-loaded chunk files, the [`output.chunkFilename`](#outputchunkfilename) option is used. Files created by loaders also aren't affected. In this case, you would have to try the specific loader's available options.
604606

605607
### Template strings
606608

0 commit comments

Comments
 (0)