{"name":"yallist","description":"Yet Another Linked List","dist-tags":{"latest":"4.0.0"},"versions":{"4.0.0":{"name":"yallist","version":"4.0.0","description":"Yet Another Linked List","main":"yallist.js","directories":{"test":"test"},"dependencies":{},"devDependencies":{"tap":"^12.1.0"},"scripts":{"test":"tap test/*.js --100","preversion":"npm test","postversion":"npm publish","postpublish":"git push origin --all; git push origin --tags"},"repository":{"type":"git","url":"git+https://github.com/isaacs/yallist.git"},"author":{"name":"Isaac Z. Schlueter","email":"i@izs.me","url":"http://blog.izs.me/"},"license":"ISC","gitHead":"1649cc57394b5affeca2c573943ebe3ed7d39119","bugs":{"url":"https://github.com/isaacs/yallist/issues"},"_id":"yallist@4.0.0","_nodeVersion":"12.8.1","_npmVersion":"6.12.0-next.0","dist":{"integrity":"sha512-3wdGidZyq5PB084XLES5TpOSRA3wjXAlIWMhum2kRcv/41Sn2emQ0dycQW4uZXLejwKvg6EsvbdlVL+FYEct7A==","shasum":"9bb92790d9c0effec63be73519e11a35019a3a72","tarball":"http://localhost:4260/yallist/yallist-4.0.0.tgz","fileCount":5,"unpackedSize":14752,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJdkmCpCRA9TVsSAnZWagAAkVgP/3zxsW6EFohtKYJOFO0J\nlkdsbK2ee8965Oy4UNyD9F+d13p47zFmrNztw+zVS+gEt9AkSpjwMomHdQAV\nJ9NBsGaG7ppjaeNNfp8CwGO2El0rILWeEr4YdhoL6wfnxa/yuQ6HeuJty097\nOZ/FP3CXPCxj8Jlos0NwjLig/Yemtt1PNNlufcDhcKX+wzftExCMir+lBBna\nq5NpnUnOQnr3+QUFqeRHXWgPh4nJLGd9NuAmu/HcrlCnu1FEd3nWrmKtEvVg\n3GZn8lK8FLteiAxS4rHaQb8QX0W9r/RGLxuvla/KXq9LfxucTStI5pLhTj3A\nZlOxZDI/v+0wXAfr3+Bcsq5sJefk0+N5h0sWc9+hl+L2yvbMiZr2e8Z67msS\n9Hl8uwvjMwtEOCTMIyBdvBVy0OCzvEHjm+2tYwd/e3VTTWzEc9zIdUirWVU/\nqcCgSMnN+8MjV+8KLdLHVjDuxQSHFlm0LcmaU5ILlKX57rKFVOVWt8ZJ3wep\nuAzfUOkmrwWR+lN58w/MIbhdwqHcMpLmgXBJEHEtbfh7Qk6yK+A/Q237YBNq\nYIIB24k7z0vcAPN82s3LxxfLxbQBzFB1mwT8NcKQCG5XJbef8V3LLJeD78iZ\n1NvS7tl8VpSUg5Vc3C5OJvmbxbFiVPZXio/nFnwwR2jNe6ukFJ/YKlSo5MrA\ny6Ty\r\n=3Dpm\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCYUnufgWErBDMXe8KslrNmcyrPV1kGU2qlaK4ZeXoazwIhAKBpS5djrxLEclmS9SbzcNwhJJW8F7NXnArMOSGiGSCv"}]},"_hasShrinkwrap":false}},"readme":"# yallist\n\nYet Another Linked List\n\nThere are many doubly-linked list implementations like it, but this\none is mine.\n\nFor when an array would be too big, and a Map can't be iterated in\nreverse order.\n\n## basic usage\n\n```js\nimport { Yallist } from 'yallist'\nvar myList = new Yallist([1, 2, 3])\nmyList.push('foo')\nmyList.unshift('bar')\n// of course pop() and shift() are there, too\nconsole.log(myList.toArray()) // ['bar', 1, 2, 3, 'foo']\nmyList.forEach(function (k) {\n // walk the list head to tail\n})\nmyList.forEachReverse(function (k, index, list) {\n // walk the list tail to head\n})\nvar myDoubledList = myList.map(function (k) {\n return k + k\n})\n// now myDoubledList contains ['barbar', 2, 4, 6, 'foofoo']\n// mapReverse is also a thing\nvar myDoubledListReverse = myList.mapReverse(function (k) {\n return k + k\n}) // ['foofoo', 6, 4, 2, 'barbar']\n\nvar reduced = myList.reduce(function (set, entry) {\n set += entry\n return set\n}, 'start')\nconsole.log(reduced) // 'startfoo123bar'\n```\n\n## api\n\nThe whole API is considered \"public\".\n\nFunctionswiththesamenameasanArraymethodworkmoreorlessthe\nsameway.\n\nThere'sreverseversionsofmostthingsbecausethat'sthepoint.\n\n###Yallist\n\nDefaultexport,theclassthatholdsandmanagesalist.\n\nCallitwitheitheraforEach-able(likeanarray)orasetof\narguments,toinitializethelist.\n\nTheArray-ishmethodsallactlikeyou'dexpect.Nomagiclength,\nthough,soifyouchangethatitwon'tautomaticallypruneoradd\nemptyspots.\n\n###Yallist.create(..)\n\nAliasforYallistfunction.Somepeoplelikefactories.\n\n####yallist.head\n\nThefirstnodeinthelist\n\n####yallist.tail\n\nThelastnodeinthelist\n\n####yallist.length\n\nThenumberofnodesinthelist.(Changethisatyourperil.Itis\nnotmagiclikeArraylength.)\n\n####yall