webpack-chain
webpack-chain copied to clipboard
`Config.node` is incorrectly assumed to always be an object
webpack-chain makes the incorrect assumption that Config.node
can never be anything other than an object, despite webpack allowing it to be set to false
.
As a result, calling config.set('node', false)
results in the value being lost and the node
property not existing in the object generated with Config.toConfig()
.
Hi! Thank you for filing this issue - I agree webpack-chain should support this case. Would you be open to creating a PR for it? :-)
Hi! Try to fix this, have a little problem, if i want to add config.node(false)
shortcut, because need a save backward compatibility, and can't make config.node
callable and ChainedMap instance at the same time:
config.node(false) // callable, need to be a function
config.node.set('global', false) // ChainedMap instance
It will be okay if i fix only config.set('node', false)
case? But i don't know how user can save boolean value to node property, and them rewrite it to ChainedMap...
@edmorley Hello! If you have a time, need PR review)