Create-react-app: Question: *** process.env.ENV is not defined, assuming 'prod' env

Created on 4 Jul 2017  路  9Comments  路  Source: facebook/create-react-app

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

low (ignored issue template)

Most helpful comment

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

All 9 comments

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!

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

Thanks for the screenshot.

This is not a warning from React or Create React App.
It comes from some third party library you鈥檙e using.
Try searching node_modules/**/*.js for this message and you鈥檒l find which library it鈥檚 coming from.

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

@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.

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

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

@mnemanja Welcome!

Thanks mayurvarma14

Since we figured out what causes it, I鈥檒l lock the thread to prevent additional +1鈥檚.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

fson picture fson  路  3Comments

alleroux picture alleroux  路  3Comments

barcher picture barcher  路  3Comments

rdamian3 picture rdamian3  路  3Comments

Aranir picture Aranir  路  3Comments