0.5.0 โข Published 4 years ago
beenvo v0.5.0
Features
- ๐ฆ ย Inspired from dotenv.
- ๐ ย Isomorphic to the moon.
- ๐ฅ ย Blaze and lightweight.
๐ฑโ๐ ย Support many files extensions (not only
.env*);- โ
ย Toml (
*.toml) support. - โ
ย Yaml (
*.ymland*.yaml) support. - โ
ย Properties (
*.iniand*.properties) support. - โ
ย Xml (
*.xml) support. - โ
ย Json (
*.json) support. - โ
ย dotEnv (
.env*) support.
- โ
ย Toml (
๐งผ Support clean up variables loaded inside
process.env.- ๐ ย Support preload (with cli). ๐ง - welcome to any kind of help ๐๐ป
- ๐ฑโ๐ค ย Strong competitor to the rest dotEnv modules.
- ๐ข ย Node.js support.
- ๐ฆ ย Deno support. ๐ง - welcome to any kind of help ๐๐ป
- ๐ ย TypeScript support.
Notes: Require Node 12+.
Installation
# npm
$ npm install beenvo
# yarn
$ yarn add beenvoUsage
This is a practical example of how to use.
# create your variables file with name `env.yaml`.
SOME_NUMBER: 1000
SOME_STRING: "don't do that"// const beenvo = require("beenvo");
import beenvo from "beenvo";
const options = { path: "env.yaml" };
beenvo(options);
// process.env.SOME_NUMBER // 1000
// process.env.SOME_STRING // "don't do that"if you want more example you can check the test folder or open an issue ๐.
OPTIONS
You can pass options object to beenvo;
options.pathโ (String) represent path to the file which contains your variables (default to '.env').options.cleanupโ (Boolean) to remove all loaded variables (default to false).
Support
If you have any problem or suggestion please open an issue.
License
MIT ยฉ Imed Jaberi