Switch to version 6: remove src/middleware.ts

This commit is contained in:
2026-06-09 23:18:52 +00:00
parent 7a8945520d
commit 949ebcfddb

View File

@@ -1,18 +0,0 @@
// @ts-expect-error next-intl middleware type incompatibility
import createMiddleware from 'next-intl/middleware';
import { locales } from './i18n';
export default createMiddleware({
locales,
defaultLocale: 'en',
localePrefix: 'as-needed',
});
export const config = {
matcher: [
'/',
'/(es|en)/:path*',
// Enable a redirect to a matching locale at the root
// '/((?!_next|_vercel|.*\..*).*)',
],
};