File tree 2 files changed +4
-28
lines changed
2 files changed +4
-28
lines changed Original file line number Diff line number Diff line change @@ -77,18 +77,6 @@ describe('should unwrap Map correctly', () => {
77
77
expectType < number > ( wm2 . get ( { } ) ! . wrap )
78
78
} )
79
79
80
- describe ( 'should unwrap extended Map correctly' , ( ) => {
81
- class ExtendendMap1 extends Map < string , { wrap : Ref < number > } > {
82
- foo = ref ( 'foo' )
83
- bar = 1
84
- }
85
-
86
- const emap1 = reactive ( new ExtendendMap1 ( ) )
87
- expectType < string > ( emap1 . foo )
88
- expectType < number > ( emap1 . bar )
89
- expectType < number > ( emap1 . get ( 'a' ) ! . wrap )
90
- } )
91
-
92
80
describe ( 'should unwrap Set correctly' , ( ) => {
93
81
const set = reactive ( new Set < Ref < number > > ( ) )
94
82
expectType < Set < Ref < number > > > ( set )
@@ -102,14 +90,3 @@ describe('should unwrap Set correctly', () => {
102
90
const ws2 = reactive ( new WeakSet < { wrap : Ref < number > } > ( ) )
103
91
expectType < WeakSet < { wrap : number } > > ( ws2 )
104
92
} )
105
-
106
- describe ( 'should unwrap extended Set correctly' , ( ) => {
107
- class ExtendendSet1 extends Set < { wrap : Ref < number > } > {
108
- foo = ref ( 'foo' )
109
- bar = 1
110
- }
111
-
112
- const eset1 = reactive ( new ExtendendSet1 ( ) )
113
- expectType < string > ( eset1 . foo )
114
- expectType < number > ( eset1 . bar )
115
- } )
Original file line number Diff line number Diff line change @@ -500,14 +500,13 @@ export type UnwrapRefSimple<T> = T extends
500
500
| { [ RawSymbol ] ?: true }
501
501
? T
502
502
: T extends Map < infer K , infer V >
503
- ? Map < K , UnwrapRefSimple < V > > & UnwrapRef < Omit < T , keyof Map < any , any > > >
503
+ ? Map < K , UnwrapRefSimple < V > >
504
504
: T extends WeakMap < infer K , infer V >
505
- ? WeakMap < K , UnwrapRefSimple < V > > &
506
- UnwrapRef < Omit < T , keyof WeakMap < any , any > > >
505
+ ? WeakMap < K , UnwrapRefSimple < V > >
507
506
: T extends Set < infer V >
508
- ? Set < UnwrapRefSimple < V > > & UnwrapRef < Omit < T , keyof Set < any > > >
507
+ ? Set < UnwrapRefSimple < V > >
509
508
: T extends WeakSet < infer V >
510
- ? WeakSet < UnwrapRefSimple < V > > & UnwrapRef < Omit < T , keyof WeakSet < any > > >
509
+ ? WeakSet < UnwrapRefSimple < V > >
511
510
: T extends ReadonlyArray < any >
512
511
? { [ K in keyof T ] : UnwrapRefSimple < T [ K ] > }
513
512
: T extends object & { [ ShallowReactiveMarker ] ?: never }
You can’t perform that action at this time.
0 commit comments