Don't set NODE_ENV in the top level of the plugin's index.js
nerdkid93 opened this issue · 0 comments
nerdkid93 commented
There is a major undocumented side-effect that occurs with importing modernizr-webpack-plugin
, namely it sets NODE_ENV
to development
if it's not already set.
See here for broken line.
This is a major anti-pattern. If NODE_ENV
needs to be defined for the plugin to work properly, then it should set it when the plugin is constructed, and even then, it should be documented somewhere that this is happening.