{"_id":"express-paginate","_rev":"37-d29c11411bd8eb3ace3913c0973ee542","name":"express-paginate","description":"Node.js pagination middleware and view helpers","dist-tags":{"latest":"1.0.2"},"versions":{"0.0.1":{"name":"express-paginate","version":"0.0.1","description":"Node.js pagination middleware and view helpers","main":"./index.js","scripts":{"prepublish":"npm prune"},"repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{},"gitHead":"ec0067760f03ca3e43d75ab9dbafebc857e2899c","_id":"express-paginate@0.0.1","_shasum":"b6b41aee0ec34755d6377e346eb3996b32100a3a","_from":".","_npmVersion":"1.4.14","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"b6b41aee0ec34755d6377e346eb3996b32100a3a","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.1.tgz","integrity":"sha512-9n7Tlssxqkf0+5jQ4FWA05R/NlAMCnAdGIsHgoCWjdf+XaJp2pr6Xcn59WWXUTrdndiNZaC2Exi3aJrk5BYtJg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIHAFOeVNWXssOFMZuNqFd9JSkNZVct9Z91MhBiV9ZgykAiEA9NV1zWD+ygpq6P8aW8Ykg9jelphkn+M5bc5bzoGz9yo="}]},"directories":{}},"0.0.2":{"name":"express-paginate","version":"0.0.2","description":"Node.js pagination middleware and view helpers","main":"./index.js","scripts":{"prepublish":"npm prune"},"repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{},"gitHead":"78e32b714a7c184e54acc20401a80a8b765c1e59","_id":"express-paginate@0.0.2","_shasum":"2b51e586b142d28cead9083de07966ad0a7a31ce","_from":".","_npmVersion":"1.4.14","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"2b51e586b142d28cead9083de07966ad0a7a31ce","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.2.tgz","integrity":"sha512-BFdk/0kaJGnru1K64m8O+AiPGDNyH3swgK5rB+jjzcS3mF5DuOoM96dp9D0CIxKl83xvvBVov7egvfKj81EOaQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIFC3ntt/oOp9a1mLm4gP0tfz3r2IcgsGJfkjLVpfYUTPAiEA6D0DBgK0pBQBhS71BB1vwb8p2j+S2Nhydt+qbkrpyMs="}]},"directories":{}},"0.0.3":{"name":"express-paginate","version":"0.0.3","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{"chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"c1703572351c9c5330842acc2d1ad963a920f69e","_id":"express-paginate@0.0.3","_shasum":"f06d58e4b5ae0c45a0fdc7a85b9c2029e31cf2c9","_from":".","_npmVersion":"2.0.0-alpha-5","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"f06d58e4b5ae0c45a0fdc7a85b9c2029e31cf2c9","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.3.tgz","integrity":"sha512-/5uX+PMoGiIJTt7XoTD5HBsOP/4/7av9C3GnFnfxCVkVnd6cPnrfRYZeUKXCq/q7gwDwzzIW0smEeip5fi8Sxg==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIGAHkFzIpoG9OfHF80U+oiSqIFTiiV1xS37khHuuru3FAiEArS6z5/3M+7fD5BhpZCrSmu8F/xBKVYVrNAp/u+walGg="}]},"directories":{}},"0.0.4":{"name":"express-paginate","version":"0.0.4","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{"chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"4c1f8b201b0435c122a1a69c5200496f9b149731","_id":"express-paginate@0.0.4","_shasum":"e673b123dce1e4e76325318ab97fdc0729535b96","_from":".","_npmVersion":"2.1.5","_nodeVersion":"0.10.32","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"e673b123dce1e4e76325318ab97fdc0729535b96","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.4.tgz","integrity":"sha512-5mg5kP2H15Vk2aO6+TJNm9H1L8GR20r9BIS+2yZShgLWcp81Wc+7E9DN7NdOhhETabw70bnJCBwTEWbSAlcSDA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIDVTqH8B+z7WSkYV4O5R31POCjOOr+uY1hiCZzbs7tv+AiAqA7x8FLuLBFgghB6bUI1+fECTot8daoJwWBKnzMz3SA=="}]},"directories":{}},"0.0.5":{"name":"express-paginate","version":"0.0.5","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{"chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"940a8cecc5f38676b625ac24c7bdee04a6ee6c62","_id":"express-paginate@0.0.5","_shasum":"ce63a8a8e0784e000614009656e3936797a844ca","_from":".","_npmVersion":"2.1.5","_nodeVersion":"0.10.32","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"ce63a8a8e0784e000614009656e3936797a844ca","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.5.tgz","integrity":"sha512-522fxX/POLTQyLMoqzlPoWQ79laCGhhYoh6mkLiePQDuKbvNCHTTmz8kWUpMTaqyR5QzgBB996DS7T+AjqwEcA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEQCIGRcM8ZmKa/hmyMmnDE952H7Gw2LhQV8ri5TM5ckxFRSAiA+/XMJXbHGWw8miPO117FEhiiuwk2Ze3/W+KudiBPLHw=="}]},"directories":{}},"0.0.6":{"name":"express-paginate","version":"0.0.6","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{"chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"1e3b4f0f61c423b3d089c755a85746cd9557e426","_id":"express-paginate@0.0.6","_shasum":"8758c223e27a28d4bfdb120389a89f3945e62b96","_from":".","_npmVersion":"2.1.5","_nodeVersion":"0.10.32","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"8758c223e27a28d4bfdb120389a89f3945e62b96","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.6.tgz","integrity":"sha512-dfVdE4S5YcUC9H5ywQqopn6AYpCs1lp7drrLD59lmK0Km86PuQoLgaQQJ594ati6t/5oZtqFqQj/5H2YctpRqw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDtkZu1+udFFtDn0sjA0A3A/MWpSOVrJihnGMmmmS0ASwIgcjI/lwniusgRbJz5ft+tdmBTpow0cpxNazFhmzQYGGg="}]},"directories":{}},"0.0.8":{"name":"express-paginate","version":"0.0.8","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{"chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"cf03aa8bfde49154bfe5595f2e5801adf5b6960d","_id":"express-paginate@0.0.8","_shasum":"2d308759aacc90738b374d0c9b9875fc9cc5e4f4","_from":".","_npmVersion":"2.1.5","_nodeVersion":"0.10.32","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"2d308759aacc90738b374d0c9b9875fc9cc5e4f4","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.8.tgz","integrity":"sha512-MRJa7JtzmczYvrDjprKrssYlY9nyp6uezH/vebGvCzO5mW7Vi29eYwvLZ6mTpNKm4ZkTj9JpfVLB8V1zH9kdoQ==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDZTgrrzNl/I3mb9ethecIMThGqNuSPlUrCYmaEGHq69AiEAhj2hUzllWG1c5cJZKgVqyuT7KnbCBI12eXE1jd9wZDI="}]},"directories":{}},"0.0.9":{"name":"express-paginate","version":"0.0.9","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{"async":"^1.4.2","chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4","reqres":"^1.2.2"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"8c8a1f9b6df07095d96d392aecc42f2598661b97","_id":"express-paginate@0.0.9","_shasum":"4fb020e6c84f34b40e0aafdc380182ba2ebc5a60","_from":".","_npmVersion":"2.14.2","_nodeVersion":"0.12.7","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"4fb020e6c84f34b40e0aafdc380182ba2ebc5a60","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.0.9.tgz","integrity":"sha512-ZEas7yBAfg0vIi766ltXXvAnXtcf4TTLA3OCwWdOzDlrppjhzvmib0tygo725Y+jzbjAhISPNfvbQ5GoJfkFZw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDd5llIWsV0dMEXt5md1xzsUHkR7Ty83PyBXH+lviWgGwIhAOm+kPyIIpNvR8NIZnDvO3hSD2L0cWFecD0Eh81gB5nG"}]},"directories":{}},"0.1.0":{"name":"express-paginate","version":"0.1.0","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash":"^2.4.1","querystring":"^0.2.0"},"devDependencies":{"async":"^1.4.2","chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4","reqres":"^1.2.2"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"1ad79de003c386fbc5cbe54ab17da9df5f891cfb","_id":"express-paginate@0.1.0","_shasum":"e6ea56d316f0cc9c5be165f6205110509ae28cfe","_from":".","_npmVersion":"2.14.4","_nodeVersion":"4.1.2","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"e6ea56d316f0cc9c5be165f6205110509ae28cfe","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.1.0.tgz","integrity":"sha512-lPQvoWH8FUatzvPe/rIo6zgnxoOkDhQb2UF2aTib3DzaggrVyifRivW90JsX7IP3oTMpX+TLtmSl4SNpXtrf7g==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIAu+YPJyUPL2Sh/rJ//gpJqFPgQQ6vR58oJ2mBJnpWAZAiEAxHlQiOsfAI+N+0cjA/p0MEE0H0WB+ZqfQ0BB4VFNaAg="}]},"directories":{}},"0.1.1":{"name":"express-paginate","version":"0.1.1","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash.assign":"^3.2.0","lodash.clone":"^3.0.3","lodash.isobject":"^3.0.2","querystring":"^0.2.0"},"devDependencies":{"async":"^1.4.2","chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4","reqres":"^1.2.2"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"5fbf52952fb07655eccd879831e075f3c0a3783d","_id":"express-paginate@0.1.1","_shasum":"c5ec55226b4ef51b76eef564dabf038bd93279cc","_from":".","_npmVersion":"3.3.12","_nodeVersion":"5.5.0","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"c5ec55226b4ef51b76eef564dabf038bd93279cc","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.1.1.tgz","integrity":"sha512-6BtNqP3Tfd2/mpoW/ovgTy2V0fp4QO0aFLCyjDkQXvHxtthISLLDWJViuI7567V7oAa+N6+PI5N+CgKZlmcinA==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCKlAw+8H/Qtsky7l+tgvtIcXUURcQwc2eXJw44gbV1HQIhAIQ6R1ihESpAPmN599Ts2qemyxBqsYZEovqBXJ3QCbIp"}]},"_npmOperationalInternal":{"host":"packages-5-east.internal.npmjs.com","tmp":"tmp/express-paginate-0.1.1.tgz_1455381103573_0.7949866387061775"},"directories":{}},"0.2.0":{"name":"express-paginate","version":"0.2.0","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash.assign":"^3.2.0","lodash.clone":"^3.0.3","lodash.isobject":"^3.0.2","querystring":"^0.2.0"},"devDependencies":{"async":"^1.4.2","chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4","reqres":"^1.2.2"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"724c1bc72a00f988a712e68f6d040c25774f3ced","_id":"express-paginate@0.2.0","_shasum":"5f65229c86f255042e89b9d00c9c5f72b3d70ae1","_from":".","_npmVersion":"3.8.3","_nodeVersion":"5.5.0","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"5f65229c86f255042e89b9d00c9c5f72b3d70ae1","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.2.0.tgz","integrity":"sha512-OrmQNV5/myXINnUz5BUNq6GBCH1Q0uohAYqICxUUR6gKoKuZH5uI6jkOV7Ner8hZYLO3mCO2Bale8wM1/bBmZw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIBj0Sa8Q0cA2bFJRwmxqjJKEZ4r6J2vBc2LLvU/fi0/jAiEAwnC/IpOVRkO0nfOEUpujmSbF8kSc4ZN0qLBx7ZEkpHs="}]},"_npmOperationalInternal":{"host":"packages-12-west.internal.npmjs.com","tmp":"tmp/express-paginate-0.2.0.tgz_1459969122583_0.46147143258713186"},"directories":{}},"0.2.1":{"name":"express-paginate","version":"0.2.1","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash.assign":"^3.2.0","lodash.clone":"^3.0.3","lodash.isobject":"^3.0.2","querystring":"^0.2.0"},"devDependencies":{"async":"^1.4.2","chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4","reqres":"^1.2.2"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"a34a719fcc308bd8d82b46a9d51dc3bf05faae09","_id":"express-paginate@0.2.1","_shasum":"65a121e8fc5a37d9eb6d5fa9b6ffae0372b90eac","_from":".","_npmVersion":"3.9.3","_nodeVersion":"6.2.1","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"65a121e8fc5a37d9eb6d5fa9b6ffae0372b90eac","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.2.1.tgz","integrity":"sha512-vlmA04YTS6V4NhC/fpRWy9g/cstDO2lqPbu9HwbziKRFaZPr9F6pece5Njv+ps1hgU+3/0t+T/yotY7rGn9p9A==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDbH4z+/OKBBlN5hTRIzUUYRceKUdkOEURJe85KsD2/QAIhALUDT2oWyvwVLBsL1+QC0dCWfFjMqfXfuXQ19YJSjFWu"}]},"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/express-paginate-0.2.1.tgz_1468513957149_0.05100921867415309"},"directories":{}},"0.2.2":{"name":"express-paginate","version":"0.2.2","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash.assign":"^3.2.0","lodash.clone":"^3.0.3","lodash.isobject":"^3.0.2","querystring":"^0.2.0"},"devDependencies":{"async":"^1.4.2","chai":"^1.9.1","istanbul":"^0.3.0","mocha":"^1.21.4","reqres":"^1.2.2"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"91a3d4205112343e4ca311fc00bdb13d04c16c4d","_id":"express-paginate@0.2.2","_shasum":"65b1f9de1cb110ff581bd2a8025e9ee1a061df99","_from":".","_npmVersion":"3.10.3","_nodeVersion":"6.6.0","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"shasum":"65b1f9de1cb110ff581bd2a8025e9ee1a061df99","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.2.2.tgz","integrity":"sha512-15Jfkt8Do85H01mDeBWvIvbjijfRpzI7Xi5Jss4NIJxrvkK44BILJX0nFc68lFLzdn4TsjxFQepUI+g1NNKCiw==","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDjW1qG5D8FJHQ3Vjg+/WoHtyujhXLGcrh3MAm2hmTbzwIgLQIVyVaJDRDmYp5yuXidiVWR1ZGuNPK85cEW4+Mruek="}]},"_npmOperationalInternal":{"host":"packages-16-east.internal.npmjs.com","tmp":"tmp/express-paginate-0.2.2.tgz_1475152424009_0.9093648677226156"},"directories":{}},"0.3.0":{"name":"express-paginate","version":"0.3.0","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash.assign":"^4.2.0","lodash.clone":"^4.5.0","lodash.isobject":"^3.0.2","querystring":"^0.2.0"},"devDependencies":{"async":"^2.5.0","chai":"^4.1.0","istanbul":"^0.4.5","mocha":"^3.4.2","reqres":"^1.2.2"},"scripts":{"prepublish":"npm prune","test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/mocha/bin/_mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/mocha/bin/_mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"2cff591e175590acaa1e1e81c99f0e5f405a93c1","_id":"express-paginate@0.3.0","_npmVersion":"5.0.0","_nodeVersion":"8.0.0","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"dist":{"integrity":"sha512-2C3Oju11+0IX0kyRVgeyzE/nFGnp764BtY0VRkvdXGsrPaMfPWxui/lSHu/DOTQ1+C1MEFJK4eYj8/ExHB8Vjw==","shasum":"2aa2eb2d8d1737e9fdcd8fab47497e905100d156","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-0.3.0.tgz","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIA73S2F2I2B/OvTtIRTO4aSWpjHy8Fece+4qW+i7/VKOAiEAn/wdFjfmRKZFegXWMPlVDGXV5cFZytfjBoIfjMnj8dc="}]},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/express-paginate-0.3.0.tgz_1500967536371_0.7475806451402605"},"directories":{}},"1.0.0":{"name":"express-paginate","version":"1.0.0","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/niftylettuce/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/niftylettuce/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/niftylettuce/express-paginate","dependencies":{"lodash.assign":"^4.2.0","lodash.clone":"^4.5.0","lodash.isobject":"^3.0.2","qs":"^6.5.1"},"devDependencies":{"async":"^2.5.0","chai":"^4.1.0","istanbul":"^0.4.5","mocha":"^5.1.1","reqres":"^2.1.0"},"scripts":{"test":"mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/.bin/mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/.bin/mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"gitHead":"b19cc141ec9968c864461f2f72083accbd501c99","_id":"express-paginate@1.0.0","_npmVersion":"5.6.0","_nodeVersion":"8.10.0","_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"dist":{"integrity":"sha512-M4+ee9YdcRoBltBYBwMcZUH589KeoVy62dBTyaZXlrggnJFGvk3Rgw0XYdL2PXN0BQROrnYskw+QxtoPsdY+AQ==","shasum":"b9ebc6b6baec7273eac916cfa55a9b5e4977666b","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-1.0.0.tgz","fileCount":10,"unpackedSize":57865,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJa6i5fCRA9TVsSAnZWagAAa/UP/i93qxQImmp5DKYZC9BT\nmEhSnaajF2EGzNFCzAa/nN3CIuKgeoPV3Cn1n0YXebqvAsiCJFApqsjfTrfZ\nXYRalnIJIBp90K/mlXYAIMp2M+80kIzhKHfBxxz2C4+HDlg1u9EWD/gp0zKW\nnC/e905qAqITI1EggfKGLeQ7yv5CPh9+n7y9S2iTin/xQPo0DYnfLiNL/uzp\nMh9C64HXP4Pc8YkfxS+NdMgclA6ZzG7mT0H+N0kAabOwUaPIQ4w4HN5QdWgS\naNzp4KRpf4nYQiJhf4+T9hmD2uVjtmDimUX3JiswLJwSnmJZP3k+vrdHya+s\nNQcGDlzUF2umpFpPTtls3NKqeCpO873mHmaQMna7YHG1YUC4y0IDJkn8Qil9\nRNiQ+2pKLEiK+l+yQjsdnxge1TJDb1cSXqztPZzt1YnSUTUUAcHS6u7Fm7cL\nOAizTOBiUg+2SCJfSL7AlC6i0AreF4MiL1SXhA1nQdzh9q95aaJV+OcuWDLu\nyeDs55x81QOsFUJxnxn7BhMfUbwulRu34j8X15Gg5K5xhmoCmzNnm3JTgWzn\nfZWdxtdAYj2Z+hXfjWr5MgePKyFBKmwEsdeiopysFSKIMTDJb9/zMfsM+86u\nb6CGYrmp6FPABSfVA6cjhvsztUuzWxDzWsYT2+TL0AVLqe/JBGdkarzfomca\nCPvf\r\n=gDzr\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIEgJZ4sDFB9Gh5EEuqu9DxTLQkys+M1JyzuNc87+jRnSAiEAltsBA1YpdIWhDMC+o5MYTf4RdtxMNiGZLH3r9uifJzY="}]},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/express-paginate_1.0.0_1525296733708_0.7558516446637118"},"_hasShrinkwrap":false},"1.0.2":{"name":"express-paginate","version":"1.0.2","description":"Node.js pagination middleware and view helpers","main":"./index.js","repository":{"type":"git","url":"git://github.com/expressjs/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"bugs":{"url":"https://github.com/expressjs/express-paginate/issues"},"license":"MIT","homepage":"https://github.com/expressjs/express-paginate","dependencies":{"lodash.assign":"^4.2.0","lodash.clone":"^4.5.0","lodash.isobject":"^3.0.2","qs":"^6.5.1"},"devDependencies":{"async":"^2.5.0","chai":"^4.1.0","istanbul":"^0.4.5","mocha":"^5.1.1","reqres":"^2.1.0"},"scripts":{"test":"node_modules/.bin/mocha --reporter spec --bail --check-leaks --require test/support/should test/","test-cov":"istanbul cover node_modules/.bin/mocha -- --reporter dot --check-leaks --require test/support/should  test/","test-travis":"istanbul cover node_modules/.bin/mocha --report lcovonly -- --reporter spec --check-leaks --require test/support/should test/"},"licenseText":"The MIT License\n\nCopyright (c) 2014- Nick Baugh <niftylettuce@gmail.com> (http://niftylettuce.com/)\n\nPermission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the \"Software\"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:\n\nThe above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.\n\nTHE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.\n","_id":"express-paginate@1.0.2","dist":{"shasum":"7d5c0214fe713aef1685daf7ada3ec5203ae1e2e","integrity":"sha512-z0VTaLrsMe4PJFifjJCC4Q11cwrveSOejicYOgFi6RzqUMPd8kIlK95x/xq6g6k6urCI2Fd3gadj3AZ9AGqguw==","tarball":"https://registry.npmjs.org/express-paginate/-/express-paginate-1.0.2.tgz","fileCount":12,"unpackedSize":29730,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJfCH5/CRA9TVsSAnZWagAADMsP+QDLYp+pWxSywtApOvUR\nNMZAh958x83RZeSIpZ46wsTJvx8rdZRBgJT4Wgx9UKZhL2cEWepqRyUdqXTm\nPjvh/Z7NfofJjKm+0P2S30M5AlRlgJA7YymV47D6dPNedGi3zzWkwOEhChFe\n/nDGHrxWzXulb+UpgAm3KWmy7CN2HhKbFOGQyPSFIAaswcx0iHYm5/cGxtPl\nXXsBw4LNUBbmEYsgMuVnibFkvsNkUtcJFQyO5tp4yWE551c6p/QiRK3SIcc9\ndvEG4pheE+fxxCRigAV/MagT3vhoMzS1/Ivt1dQ3C8yycJ/9r+Y3vG0lfBUH\nesMy9T1/lh56iqg6XJR4Bba7np3jiL9tJbQijpZhVystpfalAK3C27LkGPjJ\neRCddq7T3E+j2J6R5B9uQkpZIk4qeJ+EJqlEhJaDXuM/4XUXJVRy2AGWlfg7\nQlQFwFM59f9f5Vc1BsF80rWl5MaZOR5CmWNldBVIwCXh9wQvEKwPL84RY4vL\n6RBqtjMvvIGmIxA60TKAzF0XPTzQ05SKBjVfJmaz6uop9w0AlMg1n8DNrALK\nBdtlzAQVsQUCF+59m82UQpRjcsEKfJlk3BK4jMrK1ockrIEbgL8jS82zfTs8\nl1uSFi4tIQlSYpXriUzg9xGm/6cnQV6Nl38HTlBDT9VTN5XJ/I3bYVIoLlTH\nRdgF\r\n=9jNr\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQCddLvB+sn157Uav+CKFDxxQhf+LDfm7fe/eKFpzgeqqQIhANz6S6QAcQjEqI1nOJG2Uc7STIBk3LwLWgrTnB/LhOkD"}]},"maintainers":[{"name":"niftylettuce","email":"niftylettuce@gmail.com"}],"_npmUser":{"name":"niftylettuce","email":"niftylettuce@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/express-paginate_1.0.2_1594392191210_0.644787401572817"},"_hasShrinkwrap":false}},"readme":"\n# express-paginate\n\n[![NPM Version][npm-image]][npm-url]\n[![NPM Downloads][downloads-image]][downloads-url]\n[![Build Status][travis-image]][travis-url]\n[![Test Coverage][coveralls-image]][coveralls-url]\n[![MIT License][license-image]][license-url]\n[![Slack][slack-image]][slack-url]\n\n> Node.js pagination middleware and view helpers.\n\n**Looking for a Koa version?**  Try using <https://github.com/koajs/ctx-paginate>, which is forked directly from this package!\n\n**v0.2.0+**: As of `v0.2.0`, we now allow you to pass `?limit=0` to get infinite (all) results.  This may impose security or performance issues for your application, so we suggest you to write a quick middleware fix such as the one below, or use rate limiting middleware to prevent abuse.\n\n```js\napp.all(function(req, res, next) {\n  // set default or minimum is 10 (as it was prior to v0.2.0)\n  if (req.query.limit <= 10) req.query.limit = 10;\n  next();\n});\n```\n\n\n## Install\n\n```bash\nnpm install -S express-paginate\n```\n\n\n## API\n\n```js\nconst paginate = require('express-paginate');\n```\n\n### paginate\n\nThis creates a new instance of `express-paginate`.\n\n\n### paginate.middleware(limit, maxLimit)\n\nThis middleware validates and supplies default values to `req.skip` (an alias of `req.offset`, which can be used to skip or offset a number of records for pagination, e.g. with Mongoose you would do `Model.find().skip(req.skip)`), `req.query.limit`, `req.query.page`, `res.locals.paginate`, `res.locals.hasPreviousPages`, and `res.locals.hasNextPages`.\n\n#### Arguments\n\n* `limit` a Number to limit results returned per page (defaults to `10`)\n* `maxLimit` a Number to restrict the number of results returned to per page (defaults to `50`) &ndash; through this, users will not be able to override this limit (e.g. they can't pass `?limit=10000` and crash your server)\n\n\n### paginate.href(req)\n\nWhen you use the `paginate` middleware, it injects a view helper function called `paginate.href` as `res.locals.paginate`, which you can use in your views for paginated hyperlinks (e.g. as the `href` in `<a>Prev</a>` or `<a>Next</a>`).\n\nBy default, the view helper `paginate.href` is already executed with the inherited `req` variable, therefore it becomes a function capable of returning a String when executed.\n\nWhen executed with `req`, it will return a function with two optional arguments, `prev` (Boolean) and `params` (String).\n\nThe argument `prev` is a Boolean and is completely optional (defaults to `false`).\n\nThe argument `params` is an Object and is completely optional.\n\nPass `true` as the value for `prev` when you want to create a `<button>` or `<a>` that points to the previous page (e.g. it would generate a URL such as the one in the `href` attribute of `<a href=\"/users?page=1&limit=10\">Prev</a>` if `req.query.page` is `2`).\n\nPass an object for the value of `params` when you want to override querystring parameters &ndash; such as for filtering and sorting (e.g. it would generate a URL such as the one in the `href` attribute of `<a href=\"/users?page=1&limit=10&sort=name\">Sort By Name</a>` if `params` is equal to `{ sort: 'name' }`.\n\nNote that if you pass only one argument with a type of Object, then it will generate a `href` with the current page and use the first argument as the value for `params`.  This is useful if you only want to do something like change the filter or sort querystring param, but not increase or decrease the page number.\n\n[See the example below for an example of how implementation looks](#example).\n\n#### Arguments\n\n* `req` (**required**) &ndash; the request object returned from Express middleware invocation\n\n#### Returned function arguments when invoked with `req`\n\n* `prev` (optional) &ndash; a Boolean to determine whether or not to increment the hyperlink returned by `1` (e.g. for \"Next\" page links)\n* `params` (optional) &ndash; an Object of querystring parameters that will override the current querystring in `req.query` (note that this will also override the `page` querystring value if `page` is present as a key in the `params` object) (e.g. if you want to make a link that allows the user to change the current querystring to sort by name, you would have `params` equal to `{ sort: 'name' }`)\n\n### paginate.hasPreviousPages\n\nWhen you use the `paginate` middleware, it injects a view helper Boolean called `hasPreviousPages` as `res.locals.hasPreviousPages`, which you can use in your views for generating pagination `<a>`'s or `<button>`'s &ndash; this utilizes `req.query.page > 1` to determine the Boolean's resulting value (representing if the query has a previous page of results)\n\n\n### paginate.hasNextPages(req)\n\nWhen you use the `paginate` middleware, it injects a view helper function called `hasNextPages` as `res.locals.hasPreviousPages`, which you can use in your views for generating pagination `<a>`'s or `<button>`'s &ndash; if the function is executed, it returns a Boolean value (representing if the query has another page of results)\n\nBy default, the view helper `paginate.hasNextPages` is already executed with the inherited `req` variable, therefore it becomes a function capable of returning a Boolean when executed.\n\nWhen executed with `req`, it will return a function that accepts two required arguments called `pageCount` and `resultsCount`.\n\n#### Arguments\n\n* `req` (**required**) &ndash; the request object returned from Express middleware invocation\n\n#### Returned function arguments when invoked with `req`\n\n* `pageCount` (**required**) &ndash; a Number representing the total number of pages for the given query executed on the page\n\n### paginate.getArrayPages(req)\n\nGet all the page urls with limit.\n![petronas contest 2015-10-29 12-35-52](https://cloud.githubusercontent.com/assets/3213579/10810997/a5b0b190-7e39-11e5-9cca-fb00a2142640.png)\n\n#### Arguments\n\n* `req` (**required**) &ndash; the request object returned from Express middleware invocation\n\n#### Returned function arguments when invoked with `req`\n\n* `limit` (**optional**) &ndash; Default: 3, a Number representing the total number of pages for the given query executed on the page.\n* `pageCount` (**required**) &ndash; a Number representing the total number of pages for the given query executed on the page.\n* `currentPage` (**required**) &ndash; a Number representing the current page.\n\n\n## Example with mongoose ODM (see example 2 for Sequelize ORM)\n\n```js\n\n// # app.js\n\nconst express = require('express');\nconst paginate = require('express-paginate');\nconst app = express();\n\n// keep this before all routes that will use pagination\napp.use(paginate.middleware(10, 50));\n\napp.get('/users', async (req, res, next) => {\n\n  // This example assumes you've previously defined `Users`\n  // as `const Users = db.model('Users')` if you are using `mongoose`\n  // and that you are using Node v7.6.0+ which has async/await support\n  try {\n\n    const [ results, itemCount ] = await Promise.all([\n      Users.find({}).limit(req.query.limit).skip(req.skip).lean().exec(),\n      Users.count({})\n    ]);\n\n    const pageCount = Math.ceil(itemCount / req.query.limit);\n\n    if (req.accepts('json')) {\n      // inspired by Stripe's API response for list objects\n      res.json({\n        object: 'list',\n        has_more: paginate.hasNextPages(req)(pageCount),\n        data: results\n      });\n    } else {\n      res.render('users', {\n        users: results,\n        pageCount,\n        itemCount,\n        pages: paginate.getArrayPages(req)(3, pageCount, req.query.page)\n      });\n    }\n\n  } catch (err) {\n    next(err);\n  }\n\n});\n\napp.listen(3000);\n\n```\n\n## Example 2 with Sequelize ORM\n```js\n\n// # app.js\n\nconst express = require('express');\nconst paginate = require('express-paginate');\nconst app = express();\n\n// keep this before all routes that will use pagination\napp.use(paginate.middleware(10, 50));\n\napp.get('/users', async (req, res, next) => {\n\n  // This example assumes you've previously defined `Users`\n  // as `const Users = sequelize.define('Users',{})` if you are using `Sequelize`\n  // and that you are using Node v7.6.0+ which has async/await support\n\n  router.get(\"/all_users\", (req, res, next) => {\n    db.User.findAndCountAll({limit: req.query.limit, offset: req.skip})\n      .then(results => {\n        const itemCount = results.count;\n        const pageCount = Math.ceil(results.count / req.query.limit);\n        res.render('users/all_users', {\n          users: results.rows,\n          pageCount,\n          itemCount,\n          pages: paginate.getArrayPages(req)(3, pageCount, req.query.page)\n        });\n    }).catch(err => next(err))\n  });\n\n});\n\napp.listen(3000);\n```\n\n```pug\n\n//- users.pug\n\nh1 Users\n\n//- this will simply generate a link to sort by name\n//- note how we only have to pass the querystring param\n//- that we want to modify here, not the entire querystring\na(href=paginate.href({ sort: 'name' })) Sort by name\n\n//- this assumes you have `?age=1` or `?age=-1` in the querystring\n//- so this will basically negate the value and give you\n//- the opposite sorting order (desc with -1 or asc with 1)\na(href=paginate.href({ sort: req.query.age === '1' ? -1 : 1 })) Sort by age\n\nul\n  each user in users\n    li= user.email\n\ninclude _paginate\n```\n\n```pug\n\n//- _paginate.pug\n\n//- This examples makes use of Bootstrap 3.x pagination classes\n\nif paginate.hasPreviousPages || paginate.hasNextPages(pageCount)\n  .navigation.well-sm#pagination\n    ul.pager\n      if paginate.hasPreviousPages\n        li.previous\n          a(href=paginate.href(true)).prev\n            i.fa.fa-arrow-circle-left\n            |  Previous\n      if pages\n        each page in pages\n          a.btn.btn-default(href=page.url)= page.number\n      if paginate.hasNextPages(pageCount)\n        li.next\n          a(href=paginate.href()).next\n            | Next&nbsp;\n            i.fa.fa-arrow-circle-right\n```\n\n\n## License\n\n[MIT][license-url]\n\n\n[npm-image]: https://img.shields.io/npm/v/express-paginate.svg?style=flat\n[npm-url]: https://npmjs.org/package/express-paginate\n[travis-image]: https://img.shields.io/travis/expressjs/express-paginate.svg?style=flat\n[travis-url]: https://travis-ci.org/expressjs/express-paginate\n[coveralls-image]: https://img.shields.io/coveralls/expressjs/express-paginate.svg?style=flat\n[coveralls-url]: https://coveralls.io/r/expressjs/express-paginate?branch=master\n[downloads-image]: http://img.shields.io/npm/dm/express-paginate.svg?style=flat\n[downloads-url]: https://npmjs.org/package/express-paginate\n[license-image]: http://img.shields.io/badge/license-MIT-blue.svg?style=flat\n[license-url]: LICENSE\n[slack-url]: https://join.slack.com/t/ladjs/shared_invite/zt-fqei6z11-Bq2trhwHQxVc5x~ifiZG0g/\n[slack-image]: https://img.shields.io/badge/chat-join%20slack-brightgreen\n","maintainers":[{"email":"niftylettuce@gmail.com","name":"niftylettuce"},{"email":"npm@titanism.com","name":"titanism"}],"time":{"modified":"2022-06-17T22:29:37.054Z","created":"2014-06-12T21:50:59.966Z","0.0.1":"2014-06-12T21:50:59.966Z","0.0.2":"2014-06-13T07:50:16.572Z","0.0.3":"2014-09-04T22:31:15.802Z","0.0.4":"2014-11-12T01:06:50.299Z","0.0.5":"2014-11-18T15:12:18.831Z","0.0.6":"2015-01-21T20:52:11.688Z","0.0.7":"2015-04-14T20:07:35.639Z","0.0.8":"2015-04-14T20:53:31.803Z","0.0.9":"2015-10-07T19:00:20.480Z","0.1.0":"2015-11-11T20:20:38.594Z","0.1.1":"2016-02-13T16:31:45.668Z","0.2.0":"2016-04-06T18:58:44.737Z","0.2.1":"2016-07-14T16:32:39.752Z","0.2.2":"2016-09-29T12:33:44.974Z","0.3.0":"2017-07-25T07:25:37.435Z","1.0.0":"2018-05-02T21:32:13.842Z","1.0.1":"2019-09-09T06:27:23.661Z","1.0.2":"2020-07-10T14:43:11.361Z"},"homepage":"https://github.com/expressjs/express-paginate","repository":{"type":"git","url":"git://github.com/expressjs/express-paginate.git"},"author":{"name":"Nick Baugh","email":"niftylettuce@gmail.com"},"bugs":{"url":"https://github.com/expressjs/express-paginate/issues"},"license":"MIT","readmeFilename":"Readme.md","contributors":[{"name":"Esco Obong","email":"menzoic@gmail.com"},{"name":"Matheus Marchini","email":"matheusdot@gmail.com"},{"name":"Carlo Bernaschina"}],"users":{"sonhuytran":true,"hckhanh":true,"mr-smiley":true,"martinspinks":true,"rocket0191":true,"meeh":true,"l8niteowl":true}}