Load locale ondemand + spanish locale (#249)

This commit is contained in:
Luke Vella 2022-07-28 10:39:58 +01:00 committed by GitHub
parent 0f35bd0518
commit c2aea134ef
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
30 changed files with 700 additions and 455 deletions

View file

@ -1,6 +1,6 @@
import { NextRequest, NextResponse } from "next/server";
const supportedLocales = ["en", "de", "fr", "sv"];
const supportedLocales = ["en", "es", "de", "fr", "sv"];
export function middleware({ headers, cookies, nextUrl }: NextRequest) {
const locale =