VUE中实现iview的图标效果时遇到的一个问题

[Vue warn]: You are using the runtime-only build of Vue where the template compiler is not available. Either pre-compile the templates into render functions, or use the compiler-included build.

found in

---> <Affix>
       <Goodsinfo> at src\components\goods\goodsinfo.vue
         <App> at src\App.vue
           <Root>

上方是错误

 解决办法:iview是2.13.0版本

npm install iview@1.0.1 --save

 cnpm install iview@2.13.0 --save 

iView官方文档:http://v1.iviewui.com/components/affix

第一次安装:
包:iview
应用场景:使用图钉效果的时候
安装方式:

cnpm install iview --save/-S

第二次安装:
包:babel-plugin-import
应用场景:按需导入我们的iview组件
安装方式:

cnpm install babel-plugin-import --save/-S

 

实现按需导入

 

 

 

第一次使用VUE做项目,写了非常多的知识点,使用框架真的特别爽!!!

VUE中实现iview的图标效果

遇到的一个错误

https://www.iviewui.com/docs/guide/start

 下面这幅图可以说是写得非常清楚了

 

 

posted @ 2017-04-25 19:54  Fanyee  阅读(755)  评论(0编辑  收藏  举报