Skip to content
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

Question: *** process.env.ENV is not defined, assuming 'prod' env #2722

Closed
mnemanja opened this issue Jul 4, 2017 · 9 comments
Closed

Question: *** process.env.ENV is not defined, assuming 'prod' env #2722

mnemanja opened this issue Jul 4, 2017 · 9 comments

Comments

@mnemanja
Copy link

mnemanja commented Jul 4, 2017

Starting from version 1.0.5 I've started getting this warning message in the browser console.

I've been wondering on how to get rid of it. I know how to create a custom variable, but I'm not sure how the process.env.ENV should be defined?

  1. node -v: 6.10.0

  2. npm -v: 5.0.4

  3. npm ls react-scripts: 1.0.5

  4. Operating system: Windows 10

  5. Browser and version (if relevant): Chrome

image

Cheers,
Nemanja

@gaearon
Copy link
Contributor

gaearon commented Jul 4, 2017

Please edit the bug report to follow the issue template. You didn't specify most of the information we need to diagnose the issue. Thanks!

@gaearon
Copy link
Contributor

gaearon commented Jul 4, 2017

(At the very least we'll need the full message text, preferably a screenshot, and steps to reproduce.)

@gaearon
Copy link
Contributor

gaearon commented Jul 4, 2017

Thanks for the screenshot.

This is not a warning from React or Create React App.
It comes from some third party library you’re using.
Try searching node_modules/**/*.js for this message and you’ll find which library it’s coming from.

I don’t know how this could be related to our updates, but I can only say more if you provide a project reproducing it.

@gaearon gaearon closed this as completed Jul 4, 2017
@nerdymax
Copy link

nerdymax commented Jul 5, 2017

@mnemanja This warning comes from the latest Chrome update. Any React app I use where the ENV variable is not defined produces this error for me.

@mayurvarma14
Copy link

@mnemanja Even I had same issue, it was coming from one of the chrome extension (Grammarly for Chrome). Disabling the extension solved problem!!

@mnemanja
Copy link
Author

mnemanja commented Jul 5, 2017

Thanks @mayurvarma14, I can confirm this behavior coming from the Grammarly extension.

@mayurvarma14
Copy link

@mnemanja Welcome!

@xtremetom
Copy link

Thanks mayurvarma14

@facebook facebook locked and limited conversation to collaborators Jul 5, 2017
@gaearon
Copy link
Contributor

gaearon commented Jul 5, 2017

Since we figured out what causes it, I’ll lock the thread to prevent additional +1’s.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

5 participants