Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 8 additions & 9 deletions types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,16 +46,15 @@ export interface RenderOptions<V extends Vue, S = {}>
baseElement?: Element
}

type ConfigurationArgs = [
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

out of curiosity, is this just a syntax change because TS 3.x does not support this type definition syntax?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Correct - I believe that format is called "named tuple" which is a new TS v4 feature.

localVue: typeof Vue,
// eslint-disable-next-line @typescript-eslint/no-explicit-any
store: Store<any>,
router: Router,
]

export type ConfigurationCallback<V extends Vue> =
| ((...args: ConfigurationArgs) => Partial<ThisTypedMountOptions<V>>)
| ((...args: ConfigurationArgs) => void)
| ((
localVue: typeof Vue,
// eslint-disable-next-line @typescript-eslint/no-explicit-any
store: Store<any>,
router: Router,
) => Partial<ThisTypedMountOptions<V>>)
// eslint-disable-next-line @typescript-eslint/no-explicit-any
| ((localVue: typeof Vue, store: Store<any>, router: Router) => void)

export function render<V extends Vue>(
TestComponent: VueClass<V> | ComponentOptions<V>,
Expand Down