commerce/middleware.ts
2023-05-03 09:58:35 +02:00

14 lines
401 B
TypeScript

import createMiddleware from 'next-intl/middleware';
export default createMiddleware({
// A list of all locales that are supported
locales: ['sv', 'en', 'nn'],
// If this locale is matched, pathnames work without a prefix (e.g. `/about`)
defaultLocale: 'sv'
});
export const config = {
// Skip all paths that should not be internationalized
matcher: ['/((?!api|_next|.*\\..*).*)']
};