fix: format param force to string

This commit is contained in:
Vick Scarlet
2026-03-30 17:49:37 +08:00
parent 59a10587a7
commit f12a147093
3 changed files with 586 additions and 462 deletions

View File

@@ -12,8 +12,8 @@
"test": "vitest"
},
"devDependencies": {
"v-transform": "^2.2.0",
"vite": "^7.3.1",
"vitest": "^4.0.18"
"v-transform": "^2.2.1",
"vite": "^8.0.3",
"vitest": "^4.1.2"
}
}

1040
pnpm-lock.yaml generated

File diff suppressed because it is too large Load Diff

View File

@@ -246,7 +246,7 @@ class Life {
}
format(discription) {
return discription.replaceAll(/\{\s*[0-9a-zA-Z_-]+\s*?\}/g, (match) => this.#format(match));
return `${discription}`.replaceAll(/\{\s*[0-9a-zA-Z_-]+\s*?\}/g, (match) => this.#format(match));
}
#format(key) {