4.0.3 • Published 4 years ago

@next-with-offline/react-hook v4.0.3

Weekly downloads
144
License
MIT
Repository
github
Last release
4 years ago

@next-with-offline/react-hook

size dependencies build downloads license

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

Install

yarn add @next-with-offline/react-hook workbox-window

Basic Usage

import React from "react";

import { useOffline } from "@next-with-offline/react-hook";

export default function Component() {
  useOffline({
    offlinePath: "/offline",
    registerOptions: {},
    scriptURL: "sw.js",
    showReloadPrompt: false,
  });

  return <p>Hello World!</p>;
}
4.0.0

4 years ago

4.0.3

4 years ago

4.0.2

4 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