Skip to content

Commit 2c34fd4

Browse files
committed
types: add proper prop types
1 parent bb34a2d commit 2c34fd4

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/components/UseMediaRecorder.vue

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,9 @@ import { useMediaRecorder } from '@orbisk/vue-use-media-recorder'
33
44
const props = defineProps({
55
constraints: {
6-
type: Object,
6+
type: Object as PropType<MediaStreamConstraints>,
77
required: true,
8-
validator(value: any): boolean {
8+
validator(value: MediaStreamConstraints) {
99
if (!value?.audio && !value?.video) {
1010
console.error('constraints must have at least one of audio or video')
1111
return false
@@ -14,7 +14,7 @@ const props = defineProps({
1414
},
1515
},
1616
mediaRecorderOptions: {
17-
type: Object,
17+
type: Object as PropType<MediaRecorderOptions>,
1818
default: () => ({}),
1919
},
2020
})

0 commit comments

Comments
 (0)