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鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
馃悰 .env file override order is slightly off compared to dotenv-flow #397
Comments
Hey, thank you for opening this issue! 馃檪 To boost priority on this issue and support open source please tip the team at https://issuehunt.io/r/goatandsheep/react-native-dotenv/issues/397 |
That is bad and sloppy. I'll take a look |
I am still seeing this as an issue. .env.development is taking priority over .env.local |
I will have to double check |
@goatandsheep More info on order below: |
Hey, thank you for opening this issue! 馃檪 To boost priority on this issue and support open source please tip the team at https://issuehunt.io/r/goatandsheep/react-native-dotenv/issues/397 |
Hi @elitenas can you send me your babel configuration / reproduction details? |
Here is a barebone repro project: https://drive.google.com/file/d/1U9sGA3cvVLKW6caPdSVvip79u5ByH7E-/view?usp=sharing In the repro project, i am outputting the value of API_URL. I am seeing the value show up as http://testing.com instead of http://testing222.com. even though .env.local should have higher priority |
dotenv-flow
describes their override order as the following:.env
.env.local
.env.[environment]
.env.[environment].local
However this library's current override order is:
.env
.env.[environment]
.env.local
.env.[environment].local
with 2 and 3 swapped compared to
dotenv-flow
. This order is defined by a series of object assignments here: https://github.com/goatandsheep/react-native-dotenv/blob/main/index.js#L93-L94Can this be switched around to match
dotenv-flow
's approach instead?The text was updated successfully, but these errors were encountered: