Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

webpack env argument

    // webpack.config.js
    plugins: [
        new webpack.DefinePlugin({
            'process.env.NODE_ENV': JSON.stringify(process.env.NODE_ENV === 'production' ? 'production' : 'development')
        })
    ]
 
PREVIOUS NEXT
Tagged: #webpack #env #argument
ADD COMMENT
Topic
Name
5+6 =