From 9c13df19a6ffe0dbfa291404cdfa72c8633b7200 Mon Sep 17 00:00:00 2001 From: trisusilo48 Date: Fri, 25 Oct 2024 11:15:21 +0700 Subject: add pwa library --- next.config.mjs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'next.config.mjs') diff --git a/next.config.mjs b/next.config.mjs index 4678774..ab509d0 100644 --- a/next.config.mjs +++ b/next.config.mjs @@ -1,4 +1,11 @@ +import withPWA from 'next-pwa'; + /** @type {import('next').NextConfig} */ -const nextConfig = {}; +const nextConfig = withPWA({ + dest: 'public', + register: true, + disable: process.env.NODE_ENV === 'development', + skipWaiting: true +}); export default nextConfig; -- cgit v1.2.3