types: setup tests for built d.ts files
This commit is contained in:
@@ -2,7 +2,7 @@ import { effect, ReactiveEffect, effectStack } from './effect'
|
||||
import { Ref, UnwrapRef } from './ref'
|
||||
import { isFunction, NOOP } from '@vue/shared'
|
||||
|
||||
export interface ComputedRef<T> extends WritableComputedRef<T> {
|
||||
export interface ComputedRef<T = any> extends WritableComputedRef<T> {
|
||||
readonly value: UnwrapRef<T>
|
||||
}
|
||||
|
||||
|
||||
@@ -15,7 +15,8 @@ const convert = <T extends unknown>(val: T): T =>
|
||||
|
||||
export function ref<T extends Ref>(raw: T): T
|
||||
export function ref<T>(raw: T): Ref<T>
|
||||
export function ref(raw: unknown) {
|
||||
export function ref<T = any>(): Ref<T>
|
||||
export function ref(raw?: unknown) {
|
||||
if (isRef(raw)) {
|
||||
return raw
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user