{"name":"es6-weak-map","version":"2.0.1","description":"ECMAScript6 WeakMap polyfill","author":{"name":"Mariusz Nowak","email":"medyk@medikoo.com","url":"http://www.medikoo.com/"},"keywords":["map","weakmap","collection","es6","harmony","list","hash","gc","ponyfill"],"repository":{"type":"git","url":"git://github.com/medikoo/es6-weak-map.git"},"dependencies":{"d":"^0.1.1","es5-ext":"^0.10.8","es6-iterator":"2","es6-symbol":"3"},"devDependencies":{"tad":"^0.2.3","xlint":"^0.2.2","xlint-jslint-medikoo":"^0.1.4"},"scripts":{"lint":"node node_modules/xlint/bin/xlint --linter=node_modules/xlint-jslint-medikoo/index.js --no-cache --no-stream","lint-console":"node node_modules/xlint/bin/xlint --linter=node_modules/xlint-jslint-medikoo/index.js --watch","test":"node ./node_modules/tad/bin/tad"},"license":"MIT","readme":"# es6-weak-map\n## WeakMap collection as specified in ECMAScript6\n\n_Roughly inspired by Mark Miller's and Kris Kowal's [WeakMap implementation](https://github.com/drses/weak-map)_.\n\nDifferences are:\n- Assumes compliant ES5 environment (no weird ES3 workarounds or hacks)\n- Well modularized CJS style\n- Based on one solution.\n\n### Limitations\n\n- Will fail on non extensible objects provided as keys\n\n### Installation\n\n\t$ npm install es6-weak-map\n\nTo port it to Browser or any other (non CJS) environment, use your favorite CJS bundler. No favorite yet? Try: [Browserify](http://browserify.org/), [Webmake](https://github.com/medikoo/modules-webmake) or [Webpack](http://webpack.github.io/)\n\n### Usage\n\nIf you want to make sure your environment implements `WeakMap`, do:\n\n```javascript\nrequire('es6-weak-map/implement');\n```\n\nIf you'd like to use native version when it exists and fallback to polyfill if it doesn't, but without implementing `WeakMap` on global scope, do:\n\n```javascript\nvar WeakMap = require('es6-weak-map');\n```\n\nIf you strictly want to use polyfill even if native `WeakMap` exists, do:\n\n```javascript\nvar WeakMap = require('es6-weak-map/polyfill');\n```\n\n#### API\n\nBest is to refer to [specification](http://people.mozilla.org/~jorendorff/es6-draft.html#sec-weakmap-objects). Still if you want quick look, follow example:\n\n```javascript\nvar WeakMap = require('es6-weak-map');\n\nvar map = new WeakMap();\nvar obj = {};\n\nmap.set(obj, 'foo'); // map\nmap.get(obj);        // 'foo'\nmap.has(obj);        // true\nmap.delete(obj);     // true\nmap.get(obj);        // undefined\nmap.has(obj);        // false\nmap.set(obj, 'bar'); // map\nmap.has(obj);        // false\n```\n\n## Tests [![Build Status](https://travis-ci.org/medikoo/es6-weak-map.svg)](https://travis-ci.org/medikoo/es6-weak-map)\n\n\t$ npm test\n","readmeFilename":"README.md","bugs":{"url":"https://github.com/medikoo/es6-weak-map/issues"},"homepage":"https://github.com/medikoo/es6-weak-map","_id":"es6-weak-map@2.0.1","_shasum":"0d2bbd8827eb5fb4ba8f97fbfea50d43db21ea81","_from":"https://registry.npmjs.org/es6-weak-map/-/es6-weak-map-2.0.1.tgz","_resolved":"https://registry.npmjs.org/es6-weak-map/-/es6-weak-map-2.0.1.tgz"}