next.config.js 468 B

12345678910111213141516171819202122232425
  1. const withPWA = require("next-pwa");
  2. /**
  3. * @type {import('next').NextConfig}
  4. */
  5. const nextConfig = {
  6. reactStrictMode: true,
  7. exportPathMap: () => ({
  8. "/": { page: "/" },
  9. "/editor": { page: "/editor" },
  10. }),
  11. compiler: {
  12. styledComponents: true,
  13. },
  14. pwa: {
  15. disable: process.env.NODE_ENV === "development",
  16. dest: "public",
  17. register: true,
  18. fallbacks: {
  19. document: "/editor",
  20. },
  21. },
  22. };
  23. module.exports = withPWA(nextConfig);