Skip to content

Commit

Permalink
fix: infinite redirects
Browse files Browse the repository at this point in the history
  • Loading branch information
SuhJae committed Sep 3, 2024
1 parent 71fec3b commit 5bf2853
Showing 1 changed file with 8 additions and 9 deletions.
17 changes: 8 additions & 9 deletions nuxt.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,13 @@ export default defineNuxtConfig({
css: ["@/assets/globals.css"],
devtools: { enabled: false },
extends: ["@nuxt/ui-pro"],
modules: ["@nuxtjs/i18n", "@nuxt/ui", "@nuxt/content", "@nuxtjs/seo"],
modules: [
"@nuxtjs/i18n",
"@nuxt/ui",
"@nuxtjs/i18n",
"@nuxt/content",
"@nuxtjs/seo",
],

icon: {
provider: "server",
Expand Down Expand Up @@ -42,8 +48,7 @@ export default defineNuxtConfig({
detectBrowserLanguage: {
useCookie: true,
cookieKey: "i18n_redirected",
redirectOn: "no prefix", // Changed to avoid root-level redirect loops
alwaysRedirect: false, // Ensure that redirects only happen when necessary
redirectOn: "root", // recommended
},

locales: [
Expand Down Expand Up @@ -108,10 +113,4 @@ export default defineNuxtConfig({
"/docs": { redirect: "/docs/getting-started" },
},
compatibilityDate: "2024-07-25",

server: {
host: "0.0.0.0", // Listen on all network interfaces
port: 3000, // Ensure this matches Traefik's configuration
timing: false, // Disable timing to avoid unnecessary headers
},
});

0 comments on commit 5bf2853

Please sign in to comment.