[SOLVED] Anybody knows how to enable image-webpack-plugin only for production?

Dear webpack lords, how do you do that? image-webpack-plugin only has these options: bypassOnDebug (which has been deprecated), and disable. I read that process.env.NODE_ENV is not recognized within the webpack config, so I can’t use that to set the value for the disable option. Thanks in advance!

I’ve found a way to set that value with webpack-merge. I’ll share the code later if anyone’s interested. I can’t right now; lots of things to do.