You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
WebpackOptionsValidationError: Invalid configuration object. Webpack has been initialised using a configuration object that does not match the API schema.
- configuration.output.chunkFilename should be a string.
-> The filename of non-entry chunks as relative path inside the `output.path` directory.
What is the expected behavior?
I would expect the output.chunkFilename to also allow a function if it simply works when you don't specify the option. And use a function within the output.filename property
Bug report
What is the current behavior?
Currently
output.chunkFilename
doesn't support a function yet: https://github.com/webpack/webpack/blob/master/lib/TemplatedPathPlugin.js when reading theTemplatedPathPlugin
showed that line https://github.com/webpack/webpack/blob/master/lib/TemplatedPathPlugin.js#L143 simply fills thechunkFilename
with thefilename
if it's left empty.If the current behavior is a bug, please provide the steps to reproduce.
This works fine:
This throws an error:
Error:
What is the expected behavior?
I would expect the
output.chunkFilename
to also allow a function if it simply works when you don't specify the option. And use a function within theoutput.filename
propertyOther relevant information:
webpack version: 4.29
Node.js version: 8.15.1
Operating System: Ubuntu 18.04.2 LTS
The text was updated successfully, but these errors were encountered: