atmosphere
Node.js Environment Variable Management
Last updated 6 years ago by ryanlelek .
Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install atmosphere 
SYNC missed versions from official npm registry.

Atmosphere

Node.js Environment Variable Management

Why should I use this?

  • prevents writing "process.env" everywhere in your project's code.
  • increases testability because you can mock different environments (due to above)

How to Use

1) Install via NPM

$ npm install atmosphere

2) Initialize

// process.env can be substituted for any object
var atmo = require('atmosphere)(process.env);

3) Get Variables

// Access Environment Variables
atmo.get('port'); // 3000

Upcoming

  • Environment Variable Prefix (MYAPP_PORT -> PORT)
  • Auto-capitalization (port -> PORT)
  • Replacing spaces with underscores
  • Converting the return value to another type ('3000' -> 3000)

Current Tags

  • 0.0.2                                ...           latest (6 years ago)

2 Versions

  • 0.0.2                                ...           6 years ago
  • 0.0.1                                ...           6 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (1)
Dev Dependencies (2)
Dependents (0)
None

Copyright 2014 - 2017 © taobao.org |