From 2e1f13dc377e05ea1e8d251cacdc36fe41c590f0 Mon Sep 17 00:00:00 2001 From: ysx-hidden <394460456@qq.com> Date: Sat, 22 Jan 2022 23:46:30 +0800 Subject: [PATCH] Fixed computed not getting argument types correctly in typescript --- packages/reactivity/src/computed.ts | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/packages/reactivity/src/computed.ts b/packages/reactivity/src/computed.ts index ab0034a4cf1..04453d1f659 100644 --- a/packages/reactivity/src/computed.ts +++ b/packages/reactivity/src/computed.ts @@ -68,14 +68,14 @@ export class ComputedRefImpl { } } -export function computed( - getter: ComputedGetter, - debugOptions?: DebuggerOptions -): ComputedRef export function computed( options: WritableComputedOptions, debugOptions?: DebuggerOptions ): WritableComputedRef +export function computed( + getter: ComputedGetter, + debugOptions?: DebuggerOptions +): ComputedRef export function computed( getterOrOptions: ComputedGetter | WritableComputedOptions, debugOptions?: DebuggerOptions,