启动到另外一个项目

来源:4-2 单页面应用Demo1

qq_慕丝6268986

2020-03-26 12:05

学习 4.2章,在学习中遇到了一下几个问题,请问那位大神能否给我解答:1、我的新建里面没有 vue component 选项,vue.js已经安装,file and cod tempales 里面也显示有  但是在新建列表里就是没有  

2、我用vue serve demo1.vue 启动时  显示启动成功,点击链接却是另外一个项目 (之前学习的那个列表渲染和条件渲染的那个)

3、启动成功后前端报错 Unknown custom element: <ui> - did you register the component correctly? For recursive components, make sure to provide the "name" option.

希望老师我那位大神帮忙解答一下   感激不尽?

写回答 关注

1回答

  • Brian
    2020-04-01 11:16:59

    1、我的新建里面没有 vue component 选项,vue.js已经安装,file and cod tempales 里面也显示有  但是在新建列表里就是没有  

    ——这个问题没有看懂,有没有代码?

    2、我用vue serve demo1.vue 启动时  显示启动成功,点击链接却是另外一个项目 (之前学习的那个列表渲染和条件渲染的那个)

    ——vue serve是用来快速调试单vue文件/组件的,请使用npm run  serve运行整个vue/cli的初始化项目。

    3、启动成功后前端报错 Unknown custom element: <ui> - did you register the component correctly? For recursive components, make sure to provide the "name" option.

    ——这里提示的很明显了啊,你创建的.vue的文件,在script部分需要加上name属性

3小时速成 Vue2.x 核心技术

带你快速学习最流行的前端框架vue2.x的核心技术

82560 学习 · 487 问题

查看课程

相似问题