colophon

1.0.1 • Public • Published

Colophon

Colophon is a configuration helper with sane defaults.

File structure

Set your configuration data into this structure:

config
  default.json
  development.json
  test.json
  production.json

Override default configuration from default.json in <env>.json.

Usage

Ensure configuration uses CAPS for setting names.

Given this configuration file:

{
  "SETTING": 123
, "NESTED": {
    "SETTING": 123
  }
}

To retrieve configuration settings:

var c = require('colophon');
 
var setting = c('setting');
// setting === 123
 
var nested = c('nested:setting');
// nested === 123

Readme

Keywords

none

Package Sidebar

Install

npm i colophon

Weekly Downloads

17

Version

1.0.1

License

MIT

Last publish

Collaborators

  • recipher