- 新增产品中心功能,包括产品列表页和详情页 - 实现产品多语言支持(中文、英文、越南语) - 重构博客系统,从API获取改为本地MDX文件管理 - 更新favicon为PNG格式并修复相关引用 - 添加产品类型定义和获取逻辑 - 优化首页应用场景图片和链接 - 完善国际化配置和翻译 - 新增产品详情页标签切换组件 - 修复代理配置中的favicon路径问题
21 lines
527 B
TypeScript
21 lines
527 B
TypeScript
import createMiddleware from 'next-intl/middleware';
|
|
import { routing } from './i18n/routing';
|
|
|
|
export default createMiddleware(routing);
|
|
|
|
export const config = {
|
|
matcher: [
|
|
// Enable a redirect to a matching locale at the root
|
|
'/',
|
|
|
|
// Set a cookie to remember the previous locale for
|
|
// all requests that have a locale prefix
|
|
'/(en|zh|ja)/:path*',
|
|
|
|
// Enable redirects that add missing locales
|
|
// (e.g. `/pathnames` -> `/en/pathnames`)
|
|
'/((?!api|_next|_vercel|.*\\.|favicon.png).*)'
|
|
]
|
|
};
|
|
|