refactor: ♻️ i18n 工具类方法转换路由 title 方法名优化

Former-commit-id: 7c67972e944b06beec68a3f60fac85d3300bbdda
This commit is contained in:
hxr
2023-10-22 00:07:03 +08:00
parent ab0851d439
commit ab30d838b2
4 changed files with 8 additions and 8 deletions

View File

@@ -1,7 +1,7 @@
// translate router.meta.title, be used in breadcrumb sidebar tagsview
import i18n from "@/lang/index";
export function translateRouteTitleI18n(title: any) {
export function translateRouteTitle(title: any) {
// 判断是否存在国际化配置,如果没有原生返回
const hasKey = i18n.global.te("route." + title);
if (hasKey) {