问题: Props with type Object/Array must use a factory function to return the default value.
1、在vue中如果当在父组件通过props传Array/Object类型值给子组件的时候
2、如果子组件的props接收default为 ,如下
报错
原因:props default 数组/对象的默认值应当由一个工厂函数返回
解决:
问题: Props with type Object/Array must use a factory function to return the default value.
1、在vue中如果当在父组件通过props传Array/Object类型值给子组件的时候
2、如果子组件的props接收default为 ,如下
报错
原因:props default 数组/对象的默认值应当由一个工厂函数返回
解决: