File tree 2 files changed +19
-23
lines changed 2 files changed +19
-23
lines changed Original file line number Diff line number Diff line change @@ -49,11 +49,7 @@ type SlotDictionary = {
49
49
}
50
50
51
51
interface MountingOptions < Props , Data = { } > {
52
- data ?: ( ) => { } extends Data
53
- ? never
54
- : Data extends object
55
- ? Partial < Data >
56
- : never
52
+ data ?: ( ) => { } extends Data ? any : Data extends object ? Partial < Data > : any
57
53
props ?: Props
58
54
/** @deprecated */
59
55
propsData ?: Props
Original file line number Diff line number Diff line change 1
1
import { expectError , expectType } from 'tsd'
2
- import { DefineComponent , defineComponent } from 'vue'
2
+ import { DefineComponent , defineComponent , reactive } from 'vue'
3
3
import { mount } from '../src'
4
4
5
5
const AppWithDefine = defineComponent ( {
@@ -27,16 +27,16 @@ expectType<string>(
27
27
} ) . vm . a
28
28
)
29
29
30
- // no data provided
31
- expectError (
32
- mount ( AppWithDefine , {
33
- data ( ) {
34
- return {
35
- myVal : 1
36
- }
37
- }
38
- } )
39
- )
30
+ // // no data provided
31
+ // expectError(
32
+ // mount(AppWithDefine, {
33
+ // data() {
34
+ // return {
35
+ // myVal: 1
36
+ // }
37
+ // }
38
+ // })
39
+ // )
40
40
41
41
// can not receive extra props
42
42
expectError (
@@ -170,10 +170,10 @@ mount(ShimComponent, {
170
170
} )
171
171
172
172
// TODO it should work
173
- // mount(ShimedComponent , {
174
- // data() {
175
- // return {
176
- // a: 1
177
- // }
178
- // }
179
- // })
173
+ mount ( ShimComponent , {
174
+ data ( ) {
175
+ return {
176
+ a : 1
177
+ }
178
+ }
179
+ } )
You can’t perform that action at this time.
0 commit comments