JSPM

  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 21
  • Score
    100M100P100Q37401F
  • License MIT

lazy object maintenance

Package Exports

  • utils-config

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (utils-config) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

NPM version

utils-config

Simple configuration object maintenance

install

$ npm install utils-config

usage

var config = require('utils-config');
var proto = {};
var init = {
  hey : 'want something'
}

proto.config = config(init);
proto.config();
// { hey : 'want something'}

proto.config('hey', 'not any more');
// 'not any more'

proto.config().hey = 'come on!'
// 'come on!'

proto.config();
// { hey : 'not any more'}

var clone = proto.config({ clone : true });
var fork  = proto.config({ fork : true });

fork('hey', 'ok, continue');
// 'ok, continue'
fork('hey');
// 'ok, continue'

proto.config();
// { hey : 'ok, continue' }

clone();
// { hey : 'not anymore' }

license

LICENSE

Copyright (c) 2014 Javier Carrillo