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

support multi env files #39

Open
meishier opened this issue Jul 12, 2019 · 3 comments
Open

support multi env files #39

meishier opened this issue Jul 12, 2019 · 3 comments

Comments

@meishier
Copy link

there're two env files.
.env

AAA=aaa
BBB=bbb

.env.prod

AAA=prod

and I want get

AAA=prod
BBB=bbb

I tried to config in babe.config.js, but no luck

const plugins = [
[
'inline-dotenv',
{
path: './env/.env.prod',
},
''
],
[
'inline-dotenv',
{
path: './env/.env',
},
'inline-dotenv-base'
],

seems that inline-dotenv plugin runs only ONCE

did I miss something else? thanks

@goatandsheep
Copy link

the direction of this package is not towards dotenv flow. if that's what you need, you're better off using other packages like (shameless plug) react-native-dotenv

@wholebuzz
Copy link

wholebuzz commented Jun 25, 2021

The problem with react-native-dotenv is it doesn't work with process.env. It solves a different problem.

@goatandsheep
Copy link

react-native-dotenv is based on this library

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

No branches or pull requests

3 participants