types: setup tests for built d.ts files

This commit is contained in:
Evan You
2019-11-01 22:54:01 -04:00
parent 7b7b8ef221
commit 66ecd8b47f
14 changed files with 458 additions and 55 deletions

View File

@@ -20,8 +20,14 @@ import { SuspenseBoundary, isSuspenseType } from './suspense'
import { DirectiveBinding } from './directives'
import { SuspenseImpl } from './suspense'
export const Fragment = Symbol(__DEV__ ? 'Fragment' : undefined)
export const Portal = Symbol(__DEV__ ? 'Portal' : undefined)
export const Fragment = (Symbol(__DEV__ ? 'Fragment' : undefined) as any) as {
// type differentiator for h()
__isFragment: true
}
export const Portal = (Symbol(__DEV__ ? 'Portal' : undefined) as any) as {
// type differentiator for h()
__isPortal: true
}
export const Text = Symbol(__DEV__ ? 'Text' : undefined)
export const Comment = Symbol(__DEV__ ? 'Comment' : undefined)
@@ -47,7 +53,7 @@ export type VNodeTypes =
export interface VNodeProps {
[key: string]: any
key?: string | number
ref?: string | Ref | Function
ref?: string | Ref | ((ref: object) => void)
}
type VNodeChildAtom<HostNode, HostElement> =