前言:父级给子组件传值,子组件接收传递过来的变量报错:
Invalid default value for prop "value": Props with type Object/Array must use a factory function to return the default value.
子组件接收传参写法:
props: { value: { type: String, default: "", }, }
解决方案:把default的写法换成这样
标签:function,return,default,Invalid,value,Props,type From: https://www.cnblogs.com/iuniko/p/16730438.html