zoukankan      html  css  js  c++  java
  • VUE知识内容

    深入理解vue中的slot与slot-scope
    https://segmentfault.com/a/1190000012996217

    Vue中的computed计算属性在生命周期中的执行阶段
    https://blog.csdn.net/qq_42539194/article/details/112758839

    1、js中,.和[]都可以获取数据中的属性值。其中.主要点的是常量,[]中则可以是常量和变量
    slot是占位符,slot-scope指的是每一行数据,下面是vue中的一部分代码。table页面加载数据,占位符使用userId,然后使用userNameMap替换id,其中userNameMap中k:userId,v:姓名

            <div slot="userId" slot-scope="text">
              <div class="column-text" :title="`${text}`">{{ userNameMap[text] }}</div>
            </div>
            
    const columns = [
      {
        title: '学员名字',
        dataIndex: 'userId',
        key: 'userId',
        align: 'left',
        width: '25%',
        ellipsis: false,
        scopedSlots: { customRender: 'userId' }
      }
    
  • 相关阅读:
    刷题238. Product of Array Except Self
    刷题236. Lowest Common Ancestor of a Binary Tree
    刷题208. Implement Trie (Prefix Tree)
    A1070
    A1048
    A1050
    A1041
    A1092
    A1084
    n进制转十进制
  • 原文地址:https://www.cnblogs.com/InternetJava/p/15731306.html
Copyright © 2011-2022 走看看