因为这里使用的是第三方库,所以你要引入哈。

在app.json中引入哈。

 "usingComponents": {
"van-cell": "@vant/weapp/cell/index",
"van-cell-group": "@vant/weapp/cell-group/index"
},

虽然官网值这样说的,但是这样是要不得的,这是一个坑

引入
在app.json或index.json中引入组件,详细介绍见快速上手 "usingComponents": {
"van-cell": "path/to/@vant/weapp/dist/cell/index",
"van-cell-group": "path/to/@vant/weapp/dist/cell-group/index"
}
这样要不得哈 要将 path/to/去除 还要将 /dist去除

***这里循环的时候,不能直接在vant-cell中循环,因为这是自定义的。

所以外面在加一层view标签哈

border="{{borderfalse}}" 值为false不要下边框

custom-class="iconfont {{item.iocn}}" 自定义class。用来显示阿里字体图标库


wxml

 <view wx:for="{{gotoList}}">
<van-cell custom-class="iconfont {{item.iocn}}" is-link border="{{borderfalse}}" title="{{item.cont}}"
link-type="navigateTo" url="/pages/othertest/othertest" />
</view>
     js

 borderfalse: false, //不要边框

    // list中的跳转
gotoList: [
{
url: "/pages/othertest/othertest",
cont: "个人主页",
iocn: "icon-system"
},
{
url: "/pages/othertest/othertest",
cont: "牛人问答",
iocn: "icon-service"
},
]

最新文章

  1. [Unity3D]粒子系统学习笔记
  2. JAVA字符串格式化-String.format()的使用(转)
  3. 用computed返回this.$store.state.count,store更改了,但是computed没有调用
  4. 两台装有Ubuntu系统的服务器搭建VPN(一台为本地服务器,另一台为云服务器)
  5. MVC4在IIS6上部署遇到的问题
  6. 寒假222_codeforces 290 div 2 D
  7. C#操作XML的完整例子——XmlDocument篇(转载,仅做学习之用)
  8. webstorm 卡死解决方法
  9. 编译错误:expected an indented block
  10. 集合之ArrayList的源码分析
  11. 搭建rsync服务并同步重要数据
  12. @RequestBody, @ResponseBody 注解详解(转)
  13. Python shelve
  14. CTF密码学之凯撒加密
  15. 使用SDNN (space displacement neural network)进行多字体手写识别
  16. Redis学习基础一
  17. openstack 爬坑日记
  18. Python 入门学习(贰)文件/文件夹正则表达式批量重命名工具
  19. 【BZOJ1706】[usaco2007 Nov]relays 奶牛接力跑 矩阵乘法
  20. JS格式化数字(每三位加逗号)

热门文章

  1. Ubuntu16.04 desktop 设置共享文件夹 -- 图形界面配置
  2. Elasticsearch批量插入时,存在就不插入
  3. ES6 第七节 ES6中新增的数组知识(1)
  4. 【Weiss】【第03章】练习3.17:懒惰删除
  5. atomic的底层实现
  6. SQL Server2008执行脚本
  7. C 2015年真题
  8. Shell中的参数传递
  9. CSS劫持攻击
  10. CVE-2013-4710 WebView addJavascriptInterface远程执行代码