create-react-app — how to set EXTEND_ESLINT to true?

后端 未结 3 1473
Happy的楠姐
Happy的楠姐 2020-12-30 11:13

I have created a .env file in my project root but I\'m new to working with environments / variables and so I\'m unsure how to integrate the file so I can overri

3条回答
  •  天涯浪人
    2020-12-30 11:42

    a short answer is to just inline in the script command like

    {
      "scripts": {
        "start": "EXTEND_ESLINT=true react-scripts start"
      }
    }
    

    but this is less than ideal since you'd have to add EXTEND_ESLINT=true to all the other react-script commands as well

提交回复
热议问题