嘿你好啊
嘿你好啊
  • 发布:2020-02-24 16:55
  • 更新:2020-04-14 13:38
  • 阅读:3128

page.json自定义easycom配置custom正则匹配没生效

分类:uni-app
"easycom": {  
    "autoscan": false,  
    "custom": {  
        "uni-(.*)": "@/components/uni-ui/uni-(.*)/uni-(.*).vue",  
        "yu-(.*)": "@/components/yu-ui/yu-(.*)/yu-(.*).vue"  
    }  
},

修改后按照文档要求,修改了页面重新编译.
但还是
报错如下

index.js:24551 [Vue warn]: Unknown custom element: <uni-card> - did you register the component correctly? For recursive components, make sure to provide the "name" option.
2020-02-24 16:55 负责人:无 分享
已邀请:
2***@qq.com

2***@qq.com

"easycom": {
"autoscan": true,
"custom": {
"uni-(.)": "@/components/uni-ui/uni-(.)/uni-(.).vue",
"yu-(.
)": "@/components/yu-ui/yu-(.)/yu-(.).vue"
}
},

  • 2***@qq.com

    "autoscan": true,这个选项要为true,否则无效。

    2020-04-14 13:39

该问题目前已经被锁定, 无法添加新回复