소스 검색

revert: "fix(types): use proper array type when unwrapping reactive array (#4807)"

This reverts commit 89c54ee2b913381723048f8f26fc92ff114b3209.
Evan You 4 년 전
부모
커밋
6d46b36e7c
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      packages/reactivity/src/ref.ts

+ 1 - 1
packages/reactivity/src/ref.ts

@@ -276,7 +276,7 @@ export type UnwrapRefSimple<T> = T extends
   | RefUnwrapBailTypes[keyof RefUnwrapBailTypes]
   ? T
   : T extends Array<any>
-  ? Array<UnwrapRefSimple<T[number]>>
+  ? { [K in keyof T]: UnwrapRefSimple<T[K]> }
   : T extends object & { [ShallowReactiveMarker]?: never }
   ? {
       [P in keyof T]: P extends symbol ? T[P] : UnwrapRef<T[P]>