{"_id":"array-next","_rev":"7-00f5f318169527e225db6ba2c636fdb3","name":"array-next","description":"Advance to the next item in the array looping when hitting the end.","dist-tags":{"latest":"0.0.1"},"versions":{"0.0.1":{"name":"array-next","version":"0.0.1","description":"Advance to the next item in the array looping when hitting the end.","main":"array-next.js","scripts":{"test":"node test.js"},"repository":{"type":"git","url":"git://github.com/HenrikJoreteg/array-next"},"keywords":["util","array","index"],"author":{"name":"Henrik Joreteg","email":"henrik@andyet.net"},"license":"MIT","bugs":{"url":"https://github.com/HenrikJoreteg/array-next/issues"},"_id":"array-next@0.0.1","dist":{"shasum":"e5e4660a4c27fda8151ff7764275d00900062be1","tarball":"https://registry.npmjs.org/array-next/-/array-next-0.0.1.tgz","integrity":"sha512-sBOC/Iaz2hCcYi2XlyRfyZCRUxamlE5NJXEFjE9BTx23HALnWAFsPjGtfrAclt9o3G/38Het2yyeyOd3CEY7lg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDQfjYUKt2cC1jMPDS3vRvQdx9xVuKjHAh6tnEYZY/5+AIhAMGJB84lIWpONF503H7v8HnOWgmI+2d+g/PX7DsO/RQf"}]},"_from":".","_npmVersion":"1.3.11","_npmUser":{"name":"henrikjoreteg","email":"henrik@andyet.net"},"maintainers":[{"name":"henrikjoreteg","email":"henrik@andyet.net"}]}},"readme":"# array-next\n\nSuper tiny module that returns the `next` item in an array when given an item in the array.\n\nIf you give it the last item in the array and call `next` it will loop around and give you the first.\n\n\n## installing\n\n```\nnpm install array-next\n```\n\n## how to use\n\n```js\nvar next = require('array-next');\n\n// our demo array\nvar arr = ['a', 'b', 'c', 'd', 'e', 'f', 'g'];\n\n// if none specified next should return first\nnext(arr); // returns 'a'\n\n// when given an item in the array it returns the next one\nnext(arr, 'a'); // returns 'b'\n\n// it also loops if you give it the last item\nnext(arr, 'c'); // returns 'a'\n```\n\n\n## credits\n\nIf you like this, follow [@HenrikJoreteg](http://twitter.com/henrikjoreteg) on twitter.\n\nCheck out similar resources at: http://resources.humanjavascript.com.\n\nAnd check out my book: http://humanjavascript.com\n\n\n## unit tests? \n\nrun them with `npm test`\n\nread them here: [test.js](test.js)\n\n## license\n\nMIT\n","maintainers":[{"name":"henrikjoreteg","email":"henrik@andyet.net"}],"time":{"modified":"2022-06-13T03:28:35.961Z","created":"2013-11-11T20:59:02.620Z","0.0.1":"2013-11-11T20:59:04.545Z"},"author":{"name":"Henrik Joreteg","email":"henrik@andyet.net"},"repository":{"type":"git","url":"git://github.com/HenrikJoreteg/array-next"},"users":{"daviddias":true},"keywords":["util","array","index"],"bugs":{"url":"https://github.com/HenrikJoreteg/array-next/issues"},"license":"MIT","readmeFilename":"README.md"}