0.0.3 • Published 10 years ago

figr v0.0.3

Weekly downloads
4
License
MIT
Repository
github
Last release
10 years ago

figr

Autobootstrap your config. Looks for $CWD/config and loads the config files into a config object.

Installation

npm install figr

File Tree

- /config
--- all.js
--- development.json
--- production.js
--- staging.json
--- test.js

e.g. NODE_ENV=development would result in a merge of all's exports object and the development object. i.e. you can use module.exports or a JSON file.

API

var figr = require('figr');
var config = figr();

You can also pass in a configurable object (i.e. supports #get and #set)

e.g.

var express = require('express'),
    app = express(),
    figr = require('figr'),
    config = figr(app);

console.log(config.someProp == app.get('someProp'); //true
0.0.3

10 years ago

0.0.2

10 years ago

0.0.1

10 years ago

0.0.0

10 years ago