I am using a v-for loop in Vue component, in which a Prop options which is type of Object should be iterated.
Props are declared in separate Files.
Please see Below attachments:
Vue component :
Props are declared in, props.ts :
Note: options returns an object of strings, which i am using for checkbox or radiobutton items.
How to solve this type issue?
I solved this issue by using a default value which returns an object and by removing undefined type.
options: {
type: Object,
required: true,
describe: "Provide a collection of components to render in the group",
default: function (): unknown {
return {}
},
},
Note: i am not sure if this is the proper solution for this Type problem.