-
Notifications
You must be signed in to change notification settings - Fork 25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
DefinePlugin - not seeing variables #14
Comments
Same here~ You can only use node.js environment // #if process.env.YOUR_VARIABLE !== 'BUILD'
// DO YOUR BUSINESS HERE
// #endif |
By design in webpack, loaders run before plugins. So the variables defined by |
@deepakanand any idea how to resolve this issue? |
Just specify this variable in the Instead of new webpack.DefinePlugin({
YOUR_VARIABLE: JSON.stringify(true),
}); Use $ YOUR_VARIABLE=true webpack |
I am using define plugin to set some environment variables,
The loader doesn't seem to be picking them up?
The text was updated successfully, but these errors were encountered: