SyntaxFix
Write A Post
Hire A Developer
Questions
If you using webpack in your application, you can simply set it there, using DefinePlugin...
DefinePlugin
So in your plugin section, set the NODE_ENV to production:
plugin
production
plugins: [ new webpack.DefinePlugin({ 'process.env.NODE_ENV': '"production"', }) ]