* feat: add server settings for default board, default color scheme and default locale * chore: address pull request feedback * test: adjust unit tests to match requirements * fix: deepsource issue * chore: add deepsource as dependency to translation library * refactor: restructure language-combobox, adjust default locale for next-intl * chore: change cookie keys prefix from homarr- to homarr.
13 lines
375 B
TypeScript
13 lines
375 B
TypeScript
import createMiddleware from "next-intl/middleware";
|
|
|
|
import type { SupportedLanguage } from ".";
|
|
import { createRouting } from "./routing";
|
|
|
|
export const createI18nMiddleware = (defaultLocale: SupportedLanguage) =>
|
|
createMiddleware(createRouting(defaultLocale));
|
|
|
|
export const config = {
|
|
// Match only internationalized pathnames
|
|
matcher: ["/", "/(de|en)/:path*"],
|
|
};
|