{"name":"options-cache","description":"Simple API for managing options in JavaScript applications.","version":"0.3.0","homepage":"https://github.com/jonschlinkert/options-cache","author":{"name":"Jon Schlinkert","url":"https://github.com/jonschlinkert"},"repository":{"type":"git","url":"git://github.com/jonschlinkert/options-cache.git"},"bugs":{"url":"https://github.com/jonschlinkert/options-cache/issues"},"licenses":[{"type":"MIT","url":"https://github.com/jonschlinkert/options-cache/blob/master/LICENSE-MIT"}],"keywords":["cache","config","define","disable","disabled","enable","enabled","extend","get","javascript","node.js","obj","object","opt","option","options","opts","set"],"main":"index.js","engines":{"node":">=0.10.0"},"scripts":{"test":"mocha -R spec"},"devDependencies":{"mocha":"*","should":"^4.0.4","verb":">= 0.2.6","verb-tag-jscomments":"^0.2.0"},"dependencies":{"kind-of":"^0.1.0","object.omit":"^0.2.0"},"_id":"options-cache@0.3.0","_shasum":"fbee9d373aab07ece5fe5619cadc7f0f0c8fbd75","_from":".","_npmVersion":"1.4.9","_npmUser":{"name":"jonschlinkert","email":"github@sellside.com"},"maintainers":[{"name":"jonschlinkert","email":"github@sellside.com"},{"name":"doowb","email":"brian.woodward@gmail.com"}],"dist":{"shasum":"fbee9d373aab07ece5fe5619cadc7f0f0c8fbd75","tarball":"http://registry-npm.ywwl.com/options-cache/download/options-cache-0.3.0.tgz","integrity":"sha512-aY/2CvGfQALlAicZZS4/VcuZ8/5usY4z3uka9uspV/Wq1IlY4g9GDaOhmhYg+zPBuFP3/mMfYSOZbiMVk7UAeg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIG/eK/DsOi3tHITrGA81+XS1qK7CitHKpvHezBxj4E4RAiEA7lh/GqksjIytxOlV1JXg+6rUASn9IRNO6rzIVg0e4rc="}],"size":4703,"noattachment":false,"key":"/options-cache/-/options-cache-0.3.0.tgz"},"directories":{},"readme":"# options-cache [![NPM version](https://badge.fury.io/js/options-cache.svg)](http://badge.fury.io/js/options-cache)\n\n> Simple API for managing options in JavaScript applications.\n\n## Install\n#### Install with [npm](npmjs.org)\n\n```bash\nnpm i options-cache --save\n```\n\n## API\n### [Options](index.js#L42)\n\nCreate a new instance of `Options`.\n\n* `options` **{Object}**: Initialize with default options.    \n\n**Example:**\n\n```js\nvar util = require('util');\nvar Options = require('options-cache');\n\nfunction App(options) {\n  Options.call(this, options);\n}\nutil.inherits(App, Options);\n\nApp.prototype.a = function(value) {\n  this.enable(value);\n};\n\nApp.prototype.b = function(value) {\n  if (this.enabled(value)) {\n    // do something\n  }\n};\n```\n\n### [.option](index.js#L62)\n\nSet or get an option.\n\n* `key` **{String}**: The option name.    \n* `value` **{*}**: The value to set.    \n* `returns` **{*}**: Returns a `value` when only `key` is defined.  \n\n```js\napp.option('a', true);\napp.option('a');\n//=> true\n```\n\n### [.enabled](index.js#L96)\n\nCheck if `key` is enabled (truthy).\n\n* `key` **{String}**    \n* `returns`: {Boolean}  \n\n```js\napp.enabled('a');\n//=> false\n\napp.enable('a');\napp.enabled('a');\n//=> true\n```\n\n### [.disabled](index.js#L118)\n\nCheck if `key` is disabled (falsey).\n\n* `key` **{String}**    \n* `returns` **{Boolean}**: Returns true if `key` is disabled.  \n\n```js\napp.disabled('a');\n//=> true\n\napp.enable('a');\napp.disabled('a');\n//=> false\n```\n\n### [.enable](index.js#L137)\n\nEnable `key`.\n\n* `key` **{String}**    \n* `returns` **{Object}** `Options`: to enable chaining  \n\n**Example**\n\n```js\napp.enable('a');\n```\n\n### [.disable](index.js#L156)\n\nDisable `key`.\n\n* `key` **{String}**: The option to disable.    \n* `returns` **{Object}** `Options`: to enable chaining  \n\n**Example**\n\n```js\napp.disable('a');\n```\n\n## Author\n\n**Jon Schlinkert**\n \n+ [github/jonschlinkert](https://github.com/jonschlinkert)\n+ [twitter/jonschlinkert](http://twitter.com/jonschlinkert) \n\n## License\nCopyright (c) 2014 Jon Schlinkert, contributors.  \nReleased under the MIT license\n\n***\n\n_This file was generated by [verb-cli](https://github.com/assemble/verb-cli) on October 11, 2014._","publish_time":1413069706409,"_cnpm_publish_time":1413069706409,"dist-tags":{"latest":"0.3.1"}}