4.0.1 • Published 3 years ago

@next-with-offline/next-plugin v4.0.1

Weekly downloads
148
License
MIT
Repository
github
Last release
3 years ago

@next-with-offline/next-plugin

size dependencies build downloads license

Next.js plugin for generating a Workbox. Intended to be used alongside @next-with-offline/react-hook and @next-with-offline/service-worker. Read the top level documentation for more information about usage.

Install

yarn add @next-with-offline/next-plugin

Basic Usage

Update or create next.config.js with

const withOffline = require("@next-with-offline/next-plugin");

module.exports = withOffline({
  offline: {
    path: "/offline",
  },
  workbox: {
    dest: "public",
    swDest: "sw.js",
    swSrc: "worker.js",
    // .
    // ..
    // ... other workbox-webpack-plugin.InjectManifest options
  },
  // .
  // ..
  // ... other Next.js config
});

Add public/sw.js and public/sw.js.map to your .gitignore

public/sw.js
public/sw.js.map
4.0.1

3 years ago

4.0.0

3 years ago

3.0.7

4 years ago

3.0.6

4 years ago

3.0.5

4 years ago

3.0.4

4 years ago

3.0.3

4 years ago

3.0.2

4 years ago

3.0.1

4 years ago

3.0.0

4 years ago

2.0.2

4 years ago

2.0.1

4 years ago

2.0.0

4 years ago

1.1.0

4 years ago

1.0.0

4 years ago

0.4.1

4 years ago

0.4.0

4 years ago

0.3.3

4 years ago

0.3.2

4 years ago

0.3.0

4 years ago

0.2.4

4 years ago

0.2.3

4 years ago

0.2.2

4 years ago

0.2.0

4 years ago

0.1.7

4 years ago

0.1.6

4 years ago

0.1.5

4 years ago

0.1.4

4 years ago