File tree 3 files changed +6
-11
lines changed
3 files changed +6
-11
lines changed Original file line number Diff line number Diff line change 1
1
{
2
2
"name" : " omi" ,
3
- "version" : " 7.5.5 " ,
3
+ "version" : " 7.5.6 " ,
4
4
"scripts" : {
5
5
"start" : " vite" ,
6
6
"dev-vite" : " vite" ,
Original file line number Diff line number Diff line change @@ -18,4 +18,4 @@ export { Signal } from './signal'
18
18
export { css } from './css-tag'
19
19
export { mixin } from './options'
20
20
export { registerDirective } from './directive'
21
- export const version = '7.5.5 '
21
+ export const version = '7.5.6 '
Original file line number Diff line number Diff line change @@ -43,9 +43,6 @@ export function createElement(
43
43
...restChildren : VNode [ ] | unknown [ ]
44
44
) : VNode | VNode [ ] {
45
45
let children : VNode [ ] | undefined
46
- if ( arguments . length > 2 ) {
47
- children = restChildren . flat ( ) as VNode [ ]
48
- }
49
46
50
47
// jsx 嵌套的元素自动忽略 attrs
51
48
if ( attributes ) {
@@ -54,12 +51,10 @@ export function createElement(
54
51
attributes = { ignoreAttrs : true }
55
52
}
56
53
57
- if ( attributes . children != null ) {
58
- if ( children ) {
59
- children . push ( ...( attributes . children as VNode [ ] ) )
60
- } else {
61
- children = attributes . children as VNode [ ]
62
- }
54
+ if ( arguments . length > 2 ) {
55
+ children = restChildren . flat ( ) as VNode [ ]
56
+ } else if ( attributes . children != null ) {
57
+ children = attributes . children as VNode [ ]
63
58
delete attributes . children
64
59
}
65
60
You can’t perform that action at this time.
0 commit comments