{"_id":"next-nginx-routes","_rev":"6-43852fcd1c50ca795441575c68eecd9e","name":"next-nginx-routes","dist-tags":{"latest":"1.3.0"},"versions":{"1.0.0":{"name":"next-nginx-routes","version":"1.0.0","keywords":["Next.js","Nginx","configuration","routing","static"],"license":"MIT","_id":"next-nginx-routes@1.0.0","maintainers":[{"name":"friedjoff","email":"mail@friedjoff.de"}],"homepage":"https://geops.ch/en/blog/next-nginx-routes","bugs":{"url":"https://github.com/geops/next-nginx-routes/issues"},"bin":{"next-nginx-routes":"generate.js"},"dist":{"shasum":"44aef142995f6d87bc0a08bfec8fee823db2dc0e","tarball":"https://registry.npmjs.org/next-nginx-routes/-/next-nginx-routes-1.0.0.tgz","fileCount":15,"integrity":"sha512-D2YD1pbkNbtAJgavnR4lr3EWjPLo32j3CnRkivN4vhmqJC6GDrS77BtLMC6x6/dlQ7utVei+2DwvZChb86Dxeg==","signatures":[{"sig":"MEQCIGPUxF5N80rT2SRdydTLyahMFl5e4uRiL93OKDqOXggVAiAIz45aOq6MRFE2nmXw/9X+rosfqfjTVOeC8Zc0qzF2qQ==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":14534,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiQY18ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqUCQ/+NeAB7GZGT001UeRloRZm30zxMw6+lBs7WVi66x/E/K2b6qmj\r\nn/p/PND5HpnelRWWUy9EXcbfzcWFoxph+Uh5HZgKNC+qywOdmq9H35c8yWHt\r\nu3sKjkwmEWi2Xkwbs+YLfGJx1WcAKH2HKkrtipzlA1umChYKKYee6amZcnaw\r\nBK8YMliGd2wbgxRCnYvu/CXzEHW4+wxwqU5Gk3QlgPQtbNoeklCNLyLddZaA\r\ndm6bJh6xM3TUYuwGB70MBiTNEKdAL5TYs7AwxRxvzfp4aNKcasMeAxdlbItX\r\n9pfFDvABg/XlZR4LdVyqSvZrL+KdhLzCnEel3GBbTv5HzXanRkXF4EXuIimP\r\nBbkGgh6rQeMPdFEUhjInyg4VNy+owCZrEY+37Pnd4vkACMItAbDYlEbSbBdA\r\nxUCW2qSdKenoZ6bQhZDhJLcOQnkY9hKoDkmkerUXnFbs1N5xhQG/pIrJk9dZ\r\nbzMTRsUkhKOd/3nSVbO0LG40ynFyTchNC11vYcEqdmIiTXBTUkcxDWaoVkxL\r\nh/HS+/DaUFqFpOlr3Mt9+2bnyhRihNQO6/1q5FLuIhpZYTr+O8TBreHuPe7g\r\nOEkJwlbO/yZkmUAjHbAZRHJ0fFsn3QSBi2diXkFOdvVQx5vnga1UJajzGTCh\r\n5M7XT1zfTd9wEFw2ukoHT/9YXK2KDdLvgV4=\r\n=fEBg\r\n-----END PGP SIGNATURE-----\r\n"},"gitHead":"7426647e3447fda898df95c2a7a6608e1b9f3e4d","scripts":{"test":"jest"},"_npmUser":{"name":"friedjoff","email":"mail@friedjoff.de"},"repository":{"url":"git+https://github.com/geops/next-nginx-routes.git","type":"git"},"_npmVersion":"6.14.16","description":"Generate Nginx routing configuration for static Next.js projects.","directories":{},"_nodeVersion":"14.19.0","_hasShrinkwrap":false,"devDependencies":{"jest":"^27.5.1"},"peerDependencies":{"next":"^12.0.0"},"_npmOperationalInternal":{"tmp":"tmp/next-nginx-routes_1.0.0_1648463228012_0.06800000818244034","host":"s3://npm-registry-packages"}},"1.1.0":{"name":"next-nginx-routes","version":"1.1.0","keywords":["Next.js","Nginx","configuration","routing","static"],"license":"MIT","_id":"next-nginx-routes@1.1.0","maintainers":[{"name":"friedjoff","email":"mail@friedjoff.de"}],"homepage":"https://geops.ch/en/blog/next-nginx-routes","bugs":{"url":"https://github.com/geops/next-nginx-routes/issues"},"bin":{"next-nginx-routes":"generate.js"},"dist":{"shasum":"7b6284260ba77cf84a7d5e0d40cf9553818cf2da","tarball":"https://registry.npmjs.org/next-nginx-routes/-/next-nginx-routes-1.1.0.tgz","fileCount":21,"integrity":"sha512-3MJRF6gJxalb3O543nMJZ09+4R8qisZCj3brt5bw/v3+egKPoPtJ8hUKfvKT2pqchwfxHWsb+mmo7ejLWyeigw==","signatures":[{"sig":"MEUCIQDCx4M9kfhQj7Z89NF3C3Ybf+gcAY8judk/sFqi5uXz8gIgHR4IKC0vkOhXudln/hacmrlzIkCs9lNnptkUxdPRdKM=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":85827,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjNbKqACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqhvA//f2+wHoI8MPV6YHzL+4K5IuA9bU/76NcueyKphQH5OLcImqot\r\nI6yImbIDNsC8W0+SIhkCt29fet2E77TFK7yGqf0lSUKFrWkAlUiJJfUnECc1\r\nwtIfqUVsvK19q95NyxXKgdsD/KB//gA00sVgDKAhwBaxngB6dTTBpc7B4Mam\r\nAhd7dC6OWC08HJYdRmZfnfeqX3aQ3tD0QR14jHth5vNyIpE6d/euJMPHOGk8\r\nQWEDGMKLLiStPHovERprY6vq5Z8MKGitDBSPLjR6PkHJl4v5ConiXieLuxWJ\r\nLkHsjeEE1X+jZ/XUX914R+Z63AUSl0wNH1tXw9+x1gvlt7uhtxyiGcmQ6Uyr\r\n8+3JJC2A2qiH9MvhLEKPTdtUGIOelN98zrGg36Tg1zL9jEERvDstFbokz/b3\r\nQ6q98rwYTBOzbuB59lc2EM7HWnu7go7qAghzLnGvno2oXr7OFDtEJr7L6OVa\r\nbVT3iVHccB+J0O/lOJCCElOHsUV6yLfbCFl/W5ypRgU4Fi/UQkfsx7tsR7sS\r\ndwViCbXQG5pLKwnpLFwmSa106HqhIum2dpQwtbGnBJb16oLjFrUMQ2XL1xIE\r\nDg3trMY92rfukuwsJsRjnXhzVQq4ykSkWGoZxV0dqU9CoRZ0x5DD9vZBcAF8\r\nj53BmLQmOTzY54B0zSlJETxYZk3JQPpi0Yc=\r\n=e5wY\r\n-----END PGP SIGNATURE-----\r\n"},"gitHead":"48fd47b8a6d6b247f7451478b9e03012678f7876","scripts":{"lint":"eslint *.js","test":"jest","format":"prettier --write *.js","release":"standard-version"},"_npmUser":{"name":"friedjoff","email":"mail@friedjoff.de"},"repository":{"url":"git+https://github.com/geops/next-nginx-routes.git","type":"git"},"_npmVersion":"6.14.17","description":"Generate Nginx routing configuration for static Next.js projects.","directories":{},"_nodeVersion":"14.20.0","_hasShrinkwrap":false,"devDependencies":{"jest":"^29.1.1","eslint":"^8.24.0","prettier":"^2.7.1","standard-version":"^9.5.0","eslint-plugin-jest":"^27.0.4","eslint-plugin-prettier":"^4.2.1"},"peerDependencies":{"next":"^12.0.0"},"_npmOperationalInternal":{"tmp":"tmp/next-nginx-routes_1.1.0_1664463529949_0.0666659045116107","host":"s3://npm-registry-packages"}},"1.1.1":{"name":"next-nginx-routes","version":"1.1.1","keywords":["Next.js","Nginx","configuration","routing","static"],"license":"MIT","_id":"next-nginx-routes@1.1.1","maintainers":[{"name":"friedjoff","email":"mail@friedjoff.de"}],"homepage":"https://geops.ch/en/blog/next-nginx-routes","bugs":{"url":"https://github.com/geops/next-nginx-routes/issues"},"bin":{"next-nginx-routes":"generate.js"},"dist":{"shasum":"2b877bf943969b13af8cb1f19f3fd5626be2267e","tarball":"https://registry.npmjs.org/next-nginx-routes/-/next-nginx-routes-1.1.1.tgz","fileCount":21,"integrity":"sha512-t+QWkbOBct8beifGoHLcpaBI4XA4oFUzXY8LcLoeKjj3FP4FL6/5cEXL3pfUuNxg9h0EYpvsNmg0ZpFNhInhJA==","signatures":[{"sig":"MEYCIQCncnX/bqBqrvOLVzYavwCiOXGIBXqEuGUxkGm8dfWHCwIhAIDZJkr4z5Ix9Aa9bIvGo2kq+klhobQBEz9BXKYaadln","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":86349,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJjW3s8ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmpBCg//ftCigvRTt7Jm83x1Cw8TeVVubKOGWIVtti4yBD/z0si4QHZe\r\nIMnn/IL7ObjpArEBYqbEc3LiflkUdiYNs3143AQYRS+EczqOAUaEbPyu8mhg\r\nXaDJ446czF4M1LspuMLXtGCuaBUD2plBSNFAw6lMjrsBlWSQKDUPr3pK8wZS\r\nb1j1jAsTWKgSjQ9wfALw9ZOCKqkPMb5b15IJT3miZQImLWfvt3S7EuWEXX+R\r\nKhQLUxSG9yWQt2HLFWlruqmlsnWyom6mqZFRVMOneNt3pBDnCYFXezRH0Oki\r\nHKOXuG2q4OHsg8CO6+ugqm1eFYhCX2YdHJR8euFTn8eRrRG6KZArmk4kgVRG\r\n7t7kiS0HqKncRpOGCnO2BWegLuxxxLe+LTt9iUnGqwYEqkjHJzJ01kkESaHp\r\nMwKsuzaz8ugzndZsp+0kf6KJ9qoRbLr3sBlw4F6XeU7DB2bGxF2uk9mmkPxi\r\nekFuNZHVYaUPQ0YUqRgv03Zv4MllCXqP9uE8/ynEGAsSowMeandXv51SN+g6\r\nzUwzOPAKa/RyFeexkNvdQg88SWV/U3OEJsGArpbWcLYRhFrkuHAgvrzx5Oa2\r\n5seDa/SDPL4BhteoMPey41o2lFN2gJKhJU0LjmH0ET0Qw20iXV1IdWUZzO8J\r\nVFww0SMTITW7mthOTZeD6L9e3DFUS67GKow=\r\n=RJUg\r\n-----END PGP SIGNATURE-----\r\n"},"gitHead":"1462f3941d3f87c7fc65c126f4fae1119b988cd4","scripts":{"lint":"eslint *.js","test":"jest","format":"prettier --write *.js","release":"standard-version"},"_npmUser":{"name":"friedjoff","email":"mail@friedjoff.de"},"repository":{"url":"git+https://github.com/geops/next-nginx-routes.git","type":"git"},"_npmVersion":"6.14.17","description":"Generate Nginx routing configuration for static Next.js projects.","directories":{},"_nodeVersion":"14.20.0","_hasShrinkwrap":false,"devDependencies":{"jest":"^29.2.2","eslint":"^8.26.0","prettier":"^2.7.1","standard-version":"^9.5.0","eslint-plugin-jest":"^27.1.3","eslint-plugin-prettier":"^4.2.1"},"peerDependencies":{"next":"^12.x || ^13.x"},"_npmOperationalInternal":{"tmp":"tmp/next-nginx-routes_1.1.1_1666939708349_0.6780182440197935","host":"s3://npm-registry-packages"}},"1.2.0":{"name":"next-nginx-routes","version":"1.2.0","keywords":["export","Next.js","Nginx","configuration","routing","static"],"license":"BSD-2-Clause","_id":"next-nginx-routes@1.2.0","maintainers":[{"name":"friedjoff","email":"mail@friedjoff.de"}],"homepage":"https://geops.com/en/blog/next-nginx-routes","bugs":{"url":"https://github.com/geops/next-nginx-routes/issues"},"bin":{"next-nginx-routes":"generate.js"},"dist":{"shasum":"b151734815929f646370f4281a6c3a9b59a27968","tarball":"https://registry.npmjs.org/next-nginx-routes/-/next-nginx-routes-1.2.0.tgz","fileCount":21,"integrity":"sha512-CMAMQ27+9fqOFZA6BjG3+0mS7hCR5u8XEgvC/LEU+Z13OIpm3NC/RMKw24OKs9xQcgqBY1A4hZj5g3CDveB5nA==","signatures":[{"sig":"MEQCIBu1smZx66EVRBoxGt7aSftNxSBsDGHACaPEDCMy/U8TAiA62o01p4FP9IBdmFa57YezudFqCL71JQGSugIFHvRg8w==","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":20139},"gitHead":"45fd667d6ef19c3a86d107b7f07279f93159dee0","scripts":{"lint":"eslint *.js","test":"jest","format":"prettier --write *.js","release":"standard-version"},"_npmUser":{"name":"friedjoff","email":"mail@friedjoff.de"},"repository":{"url":"git+https://github.com/geops/next-nginx-routes.git","type":"git"},"_npmVersion":"10.2.0","description":"Generate Nginx routing configuration for static Next.js projects.","directories":{},"_nodeVersion":"21.0.0","_hasShrinkwrap":false,"devDependencies":{"jest":"^29.7.0","eslint":"^8.52.0","prettier":"^3.0.3","standard-version":"^9.5.0","eslint-plugin-jest":"^27.6.0","eslint-plugin-prettier":"^5.0.1"},"peerDependencies":{"next":"^12.x || ^13.x || ^14.x"},"_npmOperationalInternal":{"tmp":"tmp/next-nginx-routes_1.2.0_1699015447248_0.1038607218829668","host":"s3://npm-registry-packages"}},"1.2.1":{"name":"next-nginx-routes","version":"1.2.1","keywords":["export","Next.js","Nginx","configuration","routing","static"],"license":"BSD-2-Clause","_id":"next-nginx-routes@1.2.1","maintainers":[{"name":"friedjoff","email":"mail@friedjoff.de"}],"homepage":"https://geops.com/en/blog/next-nginx-routes","bugs":{"url":"https://github.com/geops/next-nginx-routes/issues"},"bin":{"next-nginx-routes":"generate.js"},"dist":{"shasum":"774cdc636e9b34436092a157660f913ef8204462","tarball":"https://registry.npmjs.org/next-nginx-routes/-/next-nginx-routes-1.2.1.tgz","fileCount":21,"integrity":"sha512-Dwr9P9xlaq3DC54OHNLC0FYuC11o9Aug6xhMTsAu5HKZth/sZhVp4BiOKxDLDcK43VyOl3a5b3aWjbwwRyn1DA==","signatures":[{"sig":"MEUCIQCF+k5sblNQy54pfFJaruD1WB7ILOl5v7RaonGm5aStEwIgQkdrsMtfLL4DWF8ng8cCf8LCYOE1x4IpXNvFSkBJlIA=","keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA"}],"unpackedSize":20453},"gitHead":"c6c81290155e45c48b8a5d3eb580c6896a2580c9","scripts":{"lint":"eslint *.js","test":"jest","format":"prettier --write *.js","release":"standard-version"},"_npmUser":{"name":"friedjoff","email":"mail@friedjoff.de"},"repository":{"url":"git+https://github.com/geops/next-nginx-routes.git","type":"git"},"_npmVersion":"10.2.0","description":"Generate Nginx routing configuration for static Next.js projects.","directories":{},"_nodeVersion":"21.0.0","_hasShrinkwrap":false,"devDependencies":{"jest":"^29.7.0","eslint":"^8.52.0","prettier":"^3.0.3","standard-version":"^9.5.0","eslint-plugin-jest":"^27.6.0","eslint-plugin-prettier":"^5.0.1"},"peerDependencies":{"next":"^12.x || ^13.x || ^14.x"},"_npmOperationalInternal":{"tmp":"tmp/next-nginx-routes_1.2.1_1699015937404_0.4845447362497606","host":"s3://npm-registry-packages"}},"1.3.0":{"name":"next-nginx-routes","description":"Generate Nginx routing configuration for static Next.js projects.","version":"1.3.0","keywords":["export","Next.js","Nginx","configuration","routing","static"],"license":"BSD-2-Clause","bin":{"next-nginx-routes":"generate.js"},"devDependencies":{"@eslint/js":"^9.13.0","eslint":"^9.13.0","eslint-config-prettier":"^9.1.0","eslint-plugin-jest":"^28.8.3","eslint-plugin-prettier":"^5.2.1","globals":"^15.11.0","jest":"^29.7.0","prettier":"^3.3.3","standard-version":"^9.5.0"},"peerDependencies":{"next":"^12.x || ^13.x || ^14.x || ^15.x"},"bugs":{"url":"https://github.com/geops/next-nginx-routes/issues"},"homepage":"https://geops.com/en/blog/next-nginx-routes","repository":{"type":"git","url":"git+https://github.com/geops/next-nginx-routes.git"},"scripts":{"format":"prettier --write *.js","lint":"eslint *.js","test":"jest","release":"standard-version"},"_id":"next-nginx-routes@1.3.0","gitHead":"b0a1801248f5563408ffb1c895cfab38b09fa39c","_nodeVersion":"18.19.1","_npmVersion":"10.2.4","dist":{"integrity":"sha512-nQUSA5tvvAxcoVJklT2DwO721EKTaBKqYRvHA+pkQXsyfSb9+4bDt7OAx4gZe3+fLHBneNam1HUttGSxO5D3wQ==","shasum":"9b3b9ec732c2e1abe13ade6594dff218f7aa3485","tarball":"https://registry.npmjs.org/next-nginx-routes/-/next-nginx-routes-1.3.0.tgz","fileCount":21,"unpackedSize":31707,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIDQqZonazPNUiTSvPC9n1H6gyxWmlvMmknqMnuNUrhn+AiEAtYrtnXIUOxF2g1iOYNtyXK4sr5xLkcWDVQD3uaRu350="}]},"_npmUser":{"name":"friedjoff","email":"mail@friedjoff.de"},"directories":{},"maintainers":[{"name":"friedjoff","email":"mail@friedjoff.de"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/next-nginx-routes_1.3.0_1729611738625_0.29813761850786635"},"_hasShrinkwrap":false}},"time":{"created":"2022-03-28T10:27:08.011Z","modified":"2024-10-22T15:42:18.994Z","1.0.0":"2022-03-28T10:27:08.186Z","1.1.0":"2022-09-29T14:58:50.124Z","1.1.1":"2022-10-28T06:48:28.583Z","1.2.0":"2023-11-03T12:44:07.434Z","1.2.1":"2023-11-03T12:52:17.586Z","1.3.0":"2024-10-22T15:42:18.836Z"},"bugs":{"url":"https://github.com/geops/next-nginx-routes/issues"},"license":"BSD-2-Clause","homepage":"https://geops.com/en/blog/next-nginx-routes","keywords":["export","Next.js","Nginx","configuration","routing","static"],"repository":{"type":"git","url":"git+https://github.com/geops/next-nginx-routes.git"},"description":"Generate Nginx routing configuration for static Next.js projects.","maintainers":[{"name":"friedjoff","email":"mail@friedjoff.de"}],"readme":"# next-nginx-routes\n\nGenerate Nginx routes configuration file for Next.js static HMTL export, also known as `output: export`.\n\nThis dependency-free [NPM package](https://www.npmjs.com/package/next-nginx-routes) provides a NPM script to convert all your Next.js routes like:\n\n```json\n{\n  \"page\": \"/[foo]\",\n  \"regex\": \"^/([^/]+?)(?:/)?$\",\n  \"routeKeys\": { \"foo\": \"foo\" },\n  \"namedRegex\": \"^/(?<foo>[^/]+?)(?:/)?$\"\n}\n```\n\n... into Nginx routes like:\n\n```nginx\nlocation ~ ^/([^/]+?)(?:/)?$ {\n  try_files /[foo].html /index.html;\n}\n```\n\nNote: currently only Next.js pages router is fully supported.\n\n## Getting started\n\n### Installation\n\n```shell\nyarn add --dev next-nginx-routes\n```\n\nMake sure [`output: \"export\"`](https://nextjs.org/docs/pages/building-your-application/deploying/static-exports#configuration) is configured in your `next.config.js` file.\n\n### Generate Nginx configuration file\n\nAdd next-nginx-routes to your build script:\n\n```json\n{\n  \"build\": \"next build && next-nginx-routes\"\n}\n```\n\nAnd run Next.js export:\n\n```shell\nyarn run build\n```\n\n### Include Nginx configuration file\n\nFinally include the generated configuration file `next-routes.conf` in your Nginx site configuration file and make the Next.js `out` directory available to Nginx.\n\n## Requirements\n\n- [Next.js](https://nextjs.org) 12 or higher\n- [Node.js](https://nodejs.org) 18 or higher\n\n## More\n\n- See [`example`](https://github.com/geops/next-nginx-routes/tree/main/example) folder for a minimal Docker example.\n- Read more about this approach in our [blog post](https://geops.ch/en/blog/next-nginx-routes).\n","readmeFilename":"README.md"}