force-env
TypeScript icon, indicating that this package has built-in type declarations

1.0.2 • Public • Published

Ensure environment variable exists. If not, throw to fail early.

import forceEnv from 'force-env'
 
const nodeEnv = forceEnv('NODE_ENV')
// => 'development', 'production', 'test', or throw if not set

Readme

Keywords

Package Sidebar

Install

npm i force-env

Weekly Downloads

7

Version

1.0.2

License

MIT

Unpacked Size

1.39 kB

Total Files

4

Last publish

Collaborators

  • stevemao