v0.2.1: i18n messages 改成深合并

initI18n 之前用 spread 浅合并:
  { ...zh_cn, ...(extra['zh-cn'] || {}) }

业务侧只要定义同名一级键(如 'user'),框架自带 user.* 全部被覆盖,
表现是控制台 [intlify] Not found 'user.operationLog' / 'user.xxx' 之类。

改成递归 deepMerge,框架 locale 在底,业务侧叠在上,同 leaf key 业务覆盖框架。
This commit is contained in:
2026-05-23 22:48:10 +08:00
parent f210ce4582
commit 9746be581d
2 changed files with 25 additions and 9 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "shrimp-admin",
"version": "0.2.0",
"version": "0.2.1",
"private": true,
"description": "Shrimp 框架前端 — 消费 ShrimpServer + ShrimpTable 契约的经典 Vue3 + Element Plus 实现",
"main": "src/index.ts",