Skip to content

Commit 418aff7

Browse files
authored
Merge pull request #117 from seevee/fix/slot-dictionary-string-index
fix: add slot dictionary type as typescript string index assignment workaround
2 parents 869c974 + ff8170c commit 418aff7

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

src/mount.ts

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,13 +31,16 @@ import { parse } from '@vue/compiler-dom'
3131

3232
type Slot = VNode | string | { render: Function } | Function
3333

34+
type SlotDictionary = {
35+
[key: string]: Slot
36+
}
37+
3438
interface MountingOptions<Props> {
3539
data?: () => Record<string, unknown>
3640
props?: Props
3741
attrs?: Record<string, unknown>
38-
slots?: {
42+
slots?: SlotDictionary & {
3943
default?: Slot
40-
[key: string]: Slot
4144
}
4245
global?: GlobalMountOptions
4346
attachTo?: HTMLElement | string

0 commit comments

Comments
 (0)