I am using Quasar framework with vue composition API and typescript on VSCode.
When trying to use a prop in the template, Vetur is giving me the error in the template Property 'open' does not exist on type 'never'
Source
<template>
<q-drawer v-model="open">
test
</q-drawer>
</template>
<script lang="ts">
import { defineComponent, ref } from '@vue/composition-api';
export default defineComponent({
name: 'AuthedLayout',
props: {
open: {
type: Boolean,
required: true
}
},
components: {},
setup() {}
});
</script>
<style></style>
Any help is appreciated
Found the issue. It was because I didn't have a return
in the setup
function. The error is misleading