Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # cfgByEnv(config)
- Your good configuration variable.
- Example:
- ```js
- // process.env.PORT => 80
- // process.env.MONGODB_URI => mongodb://localhost:53017/my-awesome-db
- cfgByEnv({
- port: 3080,
- host: '::',
- mongodb: {
- uri: 'mongodb://localhost:27017/test',
- },
- });
- // newConfig => {
- // port: 80,
- // host: '::',
- // mongodb: {
- // uri: 'mongodb://localhost:53017/my-awesome-db',
- // },
- // }
- ```
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement