create react app not picking up .env files?

前端 未结 10 2090
醉话见心
醉话见心 2020-12-12 19:52

I am using create react app to bootstrap my app.

I have added two .env files .env.development and .env.production in the root.

10条回答
  •  不思量自难忘°
    2020-12-12 20:32

    And remember not to have semi-colon after the API key in the env-file.

    REACT_APP_API_KEY = 'ae87cec695cc4heheh639d06c9274a';

    should be

    REACT_APP_API_KEY = 'ae87cec695cc44heheh1639d06c9274a'

    that was my error

提交回复
热议问题