Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
sxzz committed Dec 8, 2023
1 parent 2de519f commit 123108f
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
4 changes: 1 addition & 3 deletions packages/runtime-vapor/src/component.ts
Original file line number Diff line number Diff line change
@@ -1,14 +1,12 @@
import { EffectScope, Ref, ref } from '@vue/reactivity'

import { EMPTY_OBJ } from '@vue/shared'
import { Block } from './render'
import { type DirectiveBinding } from './directive'
import {
type ComponentPropsOptions,
type NormalizedPropsOptions,
normalizePropsOptions,
} from './componentProps'

import type { DirectiveBinding } from './directive'
import type { Data } from '@vue/shared'

export type Component = FunctionalComponent | ObjectComponent
Expand Down
5 changes: 3 additions & 2 deletions packages/runtime-vapor/src/componentProps.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// NOTE: runtime-core/src/componentProps.ts

import {
Data,
type Data,
EMPTY_ARR,
EMPTY_OBJ,
camelize,
Expand All @@ -13,7 +13,7 @@ import {
isReservedProp,
} from '@vue/shared'
import { shallowReactive, toRaw } from '@vue/reactivity'
import { type ComponentInternalInstance, type Component } from './component'
import type { ComponentInternalInstance, Component } from './component'

export type ComponentPropsOptions<P = Data> =
| ComponentObjectPropsOptions<P>
Expand Down Expand Up @@ -77,6 +77,7 @@ export function initProps(
if (rawProps) {
for (let key in rawProps) {
// key, ref are reserved and never passed down
// TODO: remove vnode
if (isReservedProp(key)) {
continue
}
Expand Down

0 comments on commit 123108f

Please sign in to comment.