{"_id":"11ty-plugin-pwa","name":"11ty-plugin-pwa","dist-tags":{"latest":"2.0.0"},"versions":{"2.0.0":{"name":"11ty-plugin-pwa","version":"2.0.0","description":"An Eleventy plugin to generate service worker for PWA using Google Workbox","main":".eleventy.js","repository":{"type":"git","url":"git+https://github.com/jmsalazardev/eleventy-plugin-pwa.git"},"keywords":["eleventy-plugin","eleventy","workbox","pwa"],"author":{"name":"José Miguel Salazar","email":"jmsalazar.dev@gmail.com","url":"https://jmsalazar.dev"},"contributors":[{"name":"Nanda Oktavera","email":"codeharuka.yusa@gmail.com","url":"https://okitavera.me/"}],"license":"MIT","dependencies":{"shimmer":"^1.2.1","workbox-build":"^4.3.0"},"devDependencies":{"@11ty/eleventy":"^1.0.0","jest":"^24.9.0","rimraf":"^3.0.0"},"scripts":{"test":"jest","coverage":"jest && codecov"},"jest":{"coverageDirectory":"./coverage/","collectCoverage":true},"bugs":{"url":"https://github.com/jmsalazardev/eleventy-plugin-pwa/issues"},"homepage":"https://github.com/jmsalazardev/eleventy-plugin-pwa#readme","directories":{"test":"test"},"gitHead":"75b03fe0ad110cdf971bb66204228289945bd1e4","_id":"11ty-plugin-pwa@2.0.0","_nodeVersion":"16.14.2","_npmVersion":"8.5.0","dist":{"integrity":"sha512-Twd4EY9WXkurDElQoIQzKeF0WOkp4kFi+OV++mP2rYKA5N5cruDgqHL667PIghh3pmOxJF0M/FNxaF9STfoLuw==","shasum":"f4dbebb724ad10da1266800be2f2f0e7e3567cb5","tarball":"https://registry.npmjs.org/11ty-plugin-pwa/-/11ty-plugin-pwa-2.0.0.tgz","fileCount":10,"unpackedSize":7524,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICc+HFcf7iwZG0UQjWivQs8Ebi+Ymn5hOfz7nS3X7mZXAiEA/z6z8MXPyz4aejk1YZEee0++uyvH68DcoZA4c9WzcYM="}],"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v4.10.10\r\nComment: https://openpgpjs.org\r\n\r\nwsFzBAEBCAAGBQJiWBJ8ACEJED1NWxICdlZqFiEECWMYAoorWMhJKdjhPU1b\r\nEgJ2VmqM3w/+KU8caedvsRJhHu4L+MyyQnCgIcZPLcLQicT6ludDi0AbgvRX\r\n5+s97H3WQ8Sveyjz5ILLhu6VRAhHp+sAEzz4Il4zm2XaM1/jfFgl4UyF7LPl\r\nexr0DuFrzSLLWYvt3t4HfHFpaiuT9F8YC04tpc2qbh8UtDemoycAlHij6eak\r\n8i/9iqsM/bDFrkycCatTltT6ixbi8bbaDIq6cv4AY16WzVhOBtiSeN/x5/oh\r\nuUuLJyXkEjmi/ZFsxO7saTeTR+BsUHK5g7O0418sH2YyGsW0NFqjuGb+w6D2\r\nqJ/pB+LMsQdC/813sxpqc7wCvuJDj+3afL1nzkDBum92eYIOgMrolMDVEG+Q\r\nslFX0xrrU5ZQFDpKphBsRx+27Sh9tXGOGhwPooNTRsocZ32gq5XN6xLpmDUM\r\nJx8BsIBlL8ul0sEgsjJDhg30QocQhPlJj2bkEZmSC+vddj1N2Tu2QwA5c9d2\r\nc+UQfWVMrmaLNlhobr0njRrFHButLcptPe3Efsvmur3vc7JBld/lWhRfhmSE\r\nNXgGUSI0zDq11nrKUMxm8o/ccWK/tgK8iQI2BIsC37rcYfJjEGpYzS3FYcNi\r\ntV8/5AVmnkR5MV11SyKaB26JomBaZNjHkWov9z6neqAtBAU5SwY3oZDsU0eQ\r\nIWQQWDiQRQvHMsDSjUYCSQ8ghDe5inKrLCA=\r\n=yC5J\r\n-----END PGP SIGNATURE-----\r\n"},"_npmUser":{"name":"jmsalazardev","email":"admin@jmsalazar.dev"},"maintainers":[{"name":"jmsalazardev","email":"admin@jmsalazar.dev"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/11ty-plugin-pwa_2.0.0_1649939068460_0.6574435808200287"},"_hasShrinkwrap":false}},"time":{"created":"2022-04-14T12:24:28.460Z","2.0.0":"2022-04-14T12:24:28.641Z","modified":"2022-04-14T12:24:28.759Z"},"maintainers":[{"name":"jmsalazardev","email":"admin@jmsalazar.dev"}],"description":"An Eleventy plugin to generate service worker for PWA using Google Workbox","homepage":"https://github.com/jmsalazardev/eleventy-plugin-pwa#readme","keywords":["eleventy-plugin","eleventy","workbox","pwa"],"repository":{"type":"git","url":"git+https://github.com/jmsalazardev/eleventy-plugin-pwa.git"},"contributors":[{"name":"Nanda Oktavera","email":"codeharuka.yusa@gmail.com","url":"https://okitavera.me/"}],"author":{"name":"José Miguel Salazar","email":"jmsalazar.dev@gmail.com","url":"https://jmsalazar.dev"},"bugs":{"url":"https://github.com/jmsalazardev/eleventy-plugin-pwa/issues"},"license":"MIT","readme":"# eleventy-plugin-pwa\n\n[![travis](https://img.shields.io/travis/okitavera/eleventy-plugin-pwa.svg?style=flat-square)](https://travis-ci.org/okitavera/eleventy-plugin-pwa)\n[![license: MIT](https://img.shields.io/badge/license-MIT-blue.svg?style=flat-square)](LICENSE)\n[![eleventy](https://img.shields.io/badge/staticgen-eleventy-%23707070.svg?style=flat-square)](https://11ty.io)\n[![code style: prettier](https://img.shields.io/badge/code_style-prettier-ff69b4.svg?style=flat-square)](https://github.com/prettier/prettier)\n[![codecov](https://img.shields.io/codecov/c/github/okitavera/eleventy-plugin-pwa.svg?style=flat-square)](https://codecov.io/gh/okitavera/eleventy-plugin-pwa)\n\n> An [Eleventy](https://11ty.io) plugin to generate service worker.\n> Using Google Workbox to generate service-worker.js based on your `dir.output`.\n\n### Note\n\nSince (at this moment) `eleventy` doesn't have any API to do a things after build process, this plugin are using monkey patch method to wrap into the `finish` function in order to run workbox properly.\n\n## Installation\n\n```bash\nnpm i eleventy-plugin-pwa\n```\n\n#### Add to eleventy config file\n\n```js\nconst pluginPWA = require(\"eleventy-plugin-pwa\");\nmodule.exports = function(eleventyConfig) {\n  eleventyConfig.addPlugin(pluginPWA);\n};\n```\n\nRead more about [Eleventy plugins](https://www.11ty.io/docs/plugins/)\n\n#### Registering Service Worker\n\n```html\n// in your header templates\n<script>\n  if (\"serviceWorker\" in navigator)\n    navigator.serviceWorker.register(\"/service-worker.js\");\n</script>\n```\n\n#### Adding Web App Manifest\n\nRead [The Web App Manifest Guide](https://developers.google.com/web/fundamentals/web-app-manifest/)\n\n## Options\n\nYou can also pass workbox generateSW options directly into the plugin.\nFor example :\n\n```js\n// overwriting destination file and more\nconst pluginPWA = require(\"eleventy-plugin-pwa\");\nmodule.exports = function(eleventyConfig) {\n  eleventyConfig.addPlugin(pluginPWA, {\n    swDest: \"./build/sw.js\",\n    globDirectory: \"./build\"\n  });\n};\n```\n\nRead more about it on [workbox generateSW module page](https://developers.google.com/web/tools/workbox/modules/workbox-build#full_generatesw_config)\n\n## License\n\nThis code is available under the [MIT license](LICENSE).\n","readmeFilename":"README.md"}