{"_id":"textio-pseudomap","_rev":"104-48e77e08b1fa3371367dbf21a579cac4","name":"textio-pseudomap","dist-tags":{"latest":"1.0.3"},"versions":{"1.0.3":{"name":"textio-pseudomap","version":"1.0.3","author":{"url":"http://blog.izs.me/","name":"Isaac Z. Schlueter","email":"i@izs.me"},"license":"ISC","_id":"textio-pseudomap@1.0.3","maintainers":[{"name":"textio","email":"admin@textio.com"}],"homepage":"https://github.com/isaacs/pseudomap#readme","bugs":{"url":"https://github.com/isaacs/pseudomap/issues"},"dist":{"shasum":"de1026189606a6ee3d8bcd7a53bec82a56782563","tarball":"https://registry.npmjs.org/textio-pseudomap/-/textio-pseudomap-1.0.3.tgz","integrity":"sha512-+U2qxvIeRznIY04ER/yYE707yJRO9Lyoh6rlOIJdixJnxGpznF41K5iDusalI9dI7EwXIp7a9PM2iCE7QxaYTA==","signatures":[{"sig":"MEUCICBGmUZOyKuC6bxyQJ3BlYtxRkif03ZVeYzzT6RONNXMAiEAvNN6kTMy4llzrlQWfPHmPdv883E5KGcKuupdevMJCJk=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}]},"main":"map.js","_from":".","_shasum":"de1026189606a6ee3d8bcd7a53bec82a56782563","gitHead":"fe9b2f4da4ab1091f290797d4f7b1b12b757543c","scripts":{"test":"tap test/*.js"},"_npmUser":{"name":"textio","email":"admin@textio.com"},"repository":{"url":"git+https://github.com/isaacs/pseudomap.git","type":"git"},"_npmVersion":"3.10.3","description":"A thing that is a lot like ES6 `Map`, but without iterators, for use in environments where `for..of` syntax and `Map` are not available.","directories":{"test":"test"},"_nodeVersion":"6.6.0","devDependencies":{"tap":"^2.3.1"},"_npmOperationalInternal":{"tmp":"tmp/textio-pseudomap-1.0.3.tgz_1483324224429_0.1891980606596917","host":"packages-18-east.internal.npmjs.com"}}},"time":{"created":"2017-01-02T02:30:26.232Z","modified":"2026-07-02T17:22:08.148Z","1.0.3":"2017-01-02T02:30:26.232Z"},"bugs":{"url":"https://github.com/isaacs/pseudomap/issues"},"author":{"url":"http://blog.izs.me/","name":"Isaac Z. Schlueter","email":"i@izs.me"},"license":"ISC","homepage":"https://github.com/isaacs/pseudomap#readme","repository":{"url":"git+https://github.com/isaacs/pseudomap.git","type":"git"},"description":"A thing that is a lot like ES6 `Map`, but without iterators, for use in environments where `for..of` syntax and `Map` are not available.","maintainers":[{"email":"admin@textio.com","name":"textio-circle"},{"email":"jensen@textio.com","name":"jensen_textio"},{"email":"bobby@textio.com","name":"bobby_textio"},{"email":"olivia@textio.com","name":"oliviagunton"},{"email":"mattie@textio.com","name":"mattiejean"},{"email":"brad@textio.com","name":"brad2"},{"email":"gregory@textio.com","name":"textio-greg"},{"email":"colin@textio.com","name":"colinjeanne-textio"}],"readme":"# pseudomap\n\nA thing that is a lot like ES6 `Map`, but without iterators, for use\nin environments where `for..of` syntax and `Map` are not available.\n\n[![Build Status](https://travis-ci.org/isaacs/pseudomap.svg?branch=master)](https://travis-ci.org/isaacs/pseudomap/) [![Coverage Status](https://coveralls.io/repos/isaacs/pseudomap/badge.svg?branch=master&service=github)](https://coveralls.io/github/isaacs/pseudomap?branch=master)\n\nIf you need iterators, or just in general a more faithful polyfill to\nES6 Maps, check out [es6-map](http://npm.im/es6-map).\n\nIf you are in an environment where `Map` is supported, then that will\nbe returned instead, unless `process.env.TEST_PSEUDOMAP` is set.\n\nYou can use any value as keys, and any value as data.  Setting again\nwith the identical key will overwrite the previous value.\n\nInternally, data is stored on an `Object.create(null)` style object.\nThe key is coerced to a string to generate the key on the internal\ndata-bag object.  The original key used is stored along with the data.\n\nIn the event of a stringified-key collision, a new key is generated by\nappending an increasing number to the stringified-key until finding\neither the intended key or an empty spot.\n\nNote that because object traversal order of plain objects is not\nguaranteed to be identical to insertion order, the insertion order\nguarantee of `Map.prototype.forEach` is not guaranteed in this\nimplementation.  However, in all versions of Node.js and V8 where this\nmodule works, `forEach` does traverse data in insertion order.\n\n## API\n\nMost of the [Map\nAPI](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Map),\nwith the following exceptions:\n\n1. A `Map` object is not an iterator.\n2. `values`, `keys`, and `entries` methods are not implemented,\n   because they return iterators.\n3. The argument to the constructor can be an Array of `[key, value]`\n   pairs, or a `Map` or `PseudoMap` object.  But, since iterators\n   aren't used, passing any plain-old iterator won't initialize the\n   map properly.\n\n## USAGE\n\nUse just like a regular ES6 Map.\n\n```javascript\nvar PseudoMap = require('pseudomap')\n\n// optionally provide a pseudomap, or an array of [key,value] pairs\n// as the argument to initialize the map with\nvar myMap = new PseudoMap()\n\nmyMap.set(1, 'number 1')\nmyMap.set('1', 'string 1')\nvar akey = {}\nvar bkey = {}\nmyMap.set(akey, { some: 'data' })\nmyMap.set(bkey, { some: 'other data' })\n```\n","readmeFilename":"README.md"}