@deanacus/env
v0.0.2
Published
Just a little safety wrapper around [`dotenv`](https://github.com/motdotla/dotenv).
Readme
@deanacus/env
Just a little safety wrapper around
dotenv.
Takes a key, and an optional path, loads .env if it hasn't already, then
checks for the existance of key on process.env, and throws if it doesn't
exist.
Install
npm install @deanacus/envUsage
import { getEnv } from '@deanacus/env';
// ...
const envValue = getEnv('key', 'optional/path/to/.env');