2022-04-27 14:00:47 +03:00
|
|
|
const withPWA = require("next-pwa");
|
2022-06-14 17:49:13 +03:00
|
|
|
const runtimeCaching = require("next-pwa/cache");
|
2022-04-27 14:00:47 +03:00
|
|
|
|
2022-04-27 13:56:24 +03:00
|
|
|
/**
|
|
|
|
* @type {import('next').NextConfig}
|
|
|
|
*/
|
2022-04-27 14:00:47 +03:00
|
|
|
const nextConfig = {
|
2022-04-16 12:36:58 +03:00
|
|
|
reactStrictMode: true,
|
2022-02-03 19:56:16 +03:00
|
|
|
exportPathMap: () => ({
|
2022-03-18 12:01:19 +03:00
|
|
|
"/": { page: "/" },
|
2022-04-27 15:44:05 +03:00
|
|
|
"/editor": { page: "/editor" },
|
2022-02-03 19:56:16 +03:00
|
|
|
}),
|
2022-03-18 12:01:19 +03:00
|
|
|
compiler: {
|
|
|
|
styledComponents: true,
|
|
|
|
},
|
2022-04-27 14:00:47 +03:00
|
|
|
pwa: {
|
2022-04-27 15:32:39 +03:00
|
|
|
disable: process.env.NODE_ENV === "development",
|
2022-06-14 17:49:13 +03:00
|
|
|
runtimeCaching,
|
2022-04-27 14:00:47 +03:00
|
|
|
dest: "public",
|
|
|
|
register: true,
|
2022-04-27 15:32:19 +03:00
|
|
|
fallbacks: {
|
|
|
|
document: "/editor",
|
|
|
|
},
|
2022-04-27 14:00:47 +03:00
|
|
|
},
|
2022-04-27 13:56:24 +03:00
|
|
|
};
|
2022-04-27 14:00:47 +03:00
|
|
|
|
|
|
|
module.exports = withPWA(nextConfig);
|