@suary/fancy-env

0.4.6 • Public • Published

fancy-env

a tool for loading enveroment and support import multiple env files

usage

add env/global.env env/dev.env env/dev.lovale.env ect. and write your environment variables in those files. in every environment

if there is LOCAL_API variables in your process.env,[env].locale.env will be load.

the [env] in [env].locale.env and [env].env means your process.env.ENV

priority of files is [env].locale.env -> [env].env -> global.env

   import fancyenv from "@suary/fancy-env"
   const obj={
       //the params you want to add in process.env but not in .env files
   }
   fancyenv(obj) //obj is a optional argument

Package Sidebar

Install

npm i @suary/fancy-env

Weekly Downloads

1

Version

0.4.6

License

ISC

Unpacked Size

5.54 kB

Total Files

7

Last publish

Collaborators

  • suary