From a0269781cf9fd552680a196859d2851c11be5996 Mon Sep 17 00:00:00 2001 From: Subham Sahu Date: Thu, 8 Sep 2022 00:17:32 +0530 Subject: [PATCH] fix: withPWA is not a function error --- frontend/next.config.js | 21 ++++----------------- 1 file changed, 4 insertions(+), 17 deletions(-) diff --git a/frontend/next.config.js b/frontend/next.config.js index f3e5eca..cca11d6 100644 --- a/frontend/next.config.js +++ b/frontend/next.config.js @@ -1,28 +1,15 @@ /** @type {import('next').NextConfig} */ const removeImports = require("next-remove-imports")(); -const withPWA = require('next-pwa')({ + +const withPWA = require('next-pwa');({ dest: 'public' -}) +}); const nextConfig = { reactStrictMode: true, swcMinify: true, - // async rewrites() { - // return [ - // { - // source: "/ms/chat/:slug*", - // destination: `http://localhost:5000/ms/chat/:slug*`, // Wrong: We want to connect to ws too - // }, - // { - // source: "/ms/impact/:slug*", - // destination: `${process.env.SERVER_URL}/ms/impact/:slug*`, // Proxy to Backend - // }, - // ]; - // }, }; -module.exports = removeImports(withPWA( - (nextConfig) -)); +module.exports = removeImports(withPWA(nextConfig));