Skip to content

Commit

Permalink
fix: allow number/boolean types as Text children
Browse files Browse the repository at this point in the history
  • Loading branch information
yyx990803 committed Mar 29, 2021
1 parent ac0d450 commit 536139c
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/runtime-core/src/h.ts
Original file line number Diff line number Diff line change
Expand Up @@ -89,12 +89,12 @@ export function h(
// text/comment
export function h(
type: typeof Text | typeof Comment,
children?: string
children?: string | number | boolean
): VNode
export function h(
type: typeof Text | typeof Comment,
props?: null,
children?: string
children?: string | number | boolean
): VNode
// fragment
export function h(type: typeof Fragment, children?: VNodeArrayChildren): VNode
Expand Down

0 comments on commit 536139c

Please sign in to comment.