//middlware.ts
import createMiddleware from "next-intl/middleware";
import { defaultLocale, supportedLocales } from "./i18n";
export default createMiddleware({
locales: supportedLocales,
defaultLocale,
localeDetection: true,
});
export const config = {
matcher: ["/", "/(de|en)/:path*"],
};
Unable to find next-intl
locale because the middleware didn’t run on this request. See https://next-intl-docs.vercel.app/docs/routing/middleware#unable-to-find-locale. The notFound()
function will be called as a result.
GET /_next/static/chunks/app/react-toastify.esm.mjs.map 404 in 72ms
Language doesn’t switch on client components
New contributor
Salik Imtiaz is a new contributor to this site. Take care in asking for clarification, commenting, and answering.
Check out our Code of Conduct.