ycb configuration merger
JavaScript
Switch branches/tags
Nothing to show
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
conf
gulp
test
.eslintrc
.gitignore
.jsbeautifyrc
.travis.yml
LICENSE
README.md
gulpfile.js
index.js
package.json

README.md

conferge

Load and merge ycb config files ready to be queried.

usage

var conferge = require('conferge');

\\ files can be either a path where files will be read from
var files = './directory';
\\ or an array of filenames
var files = [ './directory/dimension', './directory/app' ];

\\ optionally a second argument can be passed that is the location of the dimensions file
\\ or an actual dimensions object (such as the contents of a dimensions file)

\\ load all .json[5]
var config = conferge(files);

\\ config can then be queried as a ycb object
var opts = {};
console.log(config(opts));

See the tests for more details.

By default ycb calculations are cached for a quicker second retrieval. Bypass the cache by passing true as a second argument:

console.log(config(opts), true);