侧边栏壁纸
  • 累计撰写 1,960 篇文章
  • 累计创建 73 个标签
  • 累计收到 20 条评论

目 录CONTENT

文章目录

Method "computed" has type "object" in the component definition. Did you reference the function

猿哥
2022-12-20 / 0 评论 / 0 点赞 / 76 阅读 / 95 字
" "
  Method “computed” has type “object” in the  component definition. Did you reference the function correctly?

意思是:
方法“computed”在组件定义中具有类型“object”。你正确地引用了函数吗?
出现这样的问题就是 将methods方法报裹住了computed

computed: { 
        carId() { 
            if(this.addForm.goods_cat.length===3){ 
                return this.addForm.goods_cat[2]
                console.log( this.addForm.goods_cat);

            }
            return null
        }

0
博主关闭了所有页面的评论