4.0.3 • Published 5 years ago
@next-with-offline/react-hook v4.0.3
@next-with-offline/react-hook
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-windowBasic 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
5 years ago
4.0.3
5 years ago
4.0.2
5 years ago
3.0.7
6 years ago
3.0.6
6 years ago
3.0.5
6 years ago
3.0.4
6 years ago
3.0.3
6 years ago
3.0.2
6 years ago
3.0.1
6 years ago
3.0.0
6 years ago
2.0.2
6 years ago
2.0.1
6 years ago
2.0.0
6 years ago
1.1.0
6 years ago
1.0.0
6 years ago
0.4.1
6 years ago
0.4.0
6 years ago
0.3.3
6 years ago
0.3.2
6 years ago
0.3.0
6 years ago
0.2.4
6 years ago
0.2.3
6 years ago
0.2.2
6 years ago
0.2.0
6 years ago
0.1.7
6 years ago
0.1.6
6 years ago
0.1.5
6 years ago
0.1.4
6 years ago