vue Props with type Object/Array must use a factory function to return the default value.
设置props中的属性默认值为对象或数组时,不能按照以下方式:props: {tableConfig:{type: Object,default:{}}},Array/Object的默认返回值要用工厂形式返回。改为:props: {tableConfig:{type: Object,default:()=>{}}},
·
设置props中的属性默认值为对象或数组时,不能按照以下方式:
props: {
tableConfig:{
type: Object,
default:{}
}
},
Array/Object的默认返回值要用工厂形式返回。改为:
props: {
tableConfig:{
type: Object,
default:()=>{}
}
},
更多推荐
所有评论(0)