1.0.1 • Published 5 years ago
throw-env v1.0.1
throw-env
Intro
Throw if environment variable cannot be taken.
Installation
npm install throw-env
Usage
JavaScript
const throwEnv = require('throw-env').default
const token = throwEnv('ACCESS_TOKEN')
TypeScript
import throwEnv from 'throw-env'
const token: string = throwEnv('ACCESS_TOKEN')
Test
npm run test