refactor(client): use setup syntax

This commit is contained in:
syuilo
2022-09-05 18:51:23 +09:00
parent 9132c72545
commit 9db2380c20
3 changed files with 54 additions and 61 deletions

View File

@@ -30,7 +30,7 @@ export default defineComponent({
} else {
if (nextBracketOpen > 0) parsed.push(str.substr(0, nextBracketOpen));
parsed.push({
arg: str.substring(nextBracketOpen + 1, nextBracketClose)
arg: str.substring(nextBracketOpen + 1, nextBracketClose),
});
}
@@ -38,5 +38,5 @@ export default defineComponent({
}
return h(this.tag, parsed.map(x => typeof x === 'string' ? (this.textTag ? h(this.textTag, x) : x) : this.$slots[x.arg]()));
}
},
});