Important: This documentation covers Yarn 1 (Classic).
For Yarn 2+ docs and migration guide, see yarnpkg.com.

Package detail

next-workbox

ragingwind170MIT2.1.0

Next.js plugins for workbox and PWA

next, next-workbox, workbox, pwa, progressive web app, next-plugins

readme

next-workbox

Next.js plugin for workbox. The plugin help you to use service worker for Next.js and now 2.0

Installation

npm install --save-dev next-workbox

or

yarn add -D next-workbox

Usage

// next.config.js
const withWorkbox = require('next-workbox');

module.exports = withWorkbox({
  generateBuildId: async () => {
    // You must have own custom build id
    return 'my-build-id';
  }
});

License

MIT © Jimmy Moon