zoukankan      html  css  js  c++  java
  • 常用问题记录(更新中)

    1、elementui table 合计行不显示
     

    # 第一种解决方法 
     /deep/
     .el-table__footer-wrapper{
       position: fixed;
    }
    
    # 第二种解决方法,我是加在 :summary-method="getSummaries"  getSummaries这个函数体内。
    
    this.$nextTick(() => {
            this.$refs.table.doLayout();
    });
    
    # 两种方法都试过,有效(2019-10-16)

    2、Support for the experimental syntax 'decorators-legacy' isn't currently

    // babel < 7
    babel-plugin-transform-decorators-legacy
    /package.json
    "plugins": ["transform-decorators-legacy"// babel > 7
    @babel/plugin-proposal-decorators

    "plugins": [
    ["@babel/plugin-proposal-decorators", { "legacy": true }],
    //...
    ]

    // 使用的是creat-react-app 创建的,babel 7+ 使用以上方案仍然报错
    // 最终解决方案:
    yarn add customize-cra @babel/plugin-proposal-decorators react-app-rewired
    // 修改package.json
    "scripts": {
    "start": "react-scripts start",
    "start": "react-app-rewired start",
    //...
    }
    // 根目录新建/config-overrides.js
    const { override,addDecoratorsLegacy } = require("customize-cra");
      module.exports = override(
        addDecoratorsLegacy(),
      );
     

    --

  • 相关阅读:
    HEOI2017游记
    uoj228:基础数据结构练习题
    bzoj1494【Noi2007】生成树计数
    bzoj1975【Sdoi2010】魔法猪学院
    bzoj2957:楼房重建
    uoj169:元旦老人与数列
    bzoj2178:圆的面积并
    一道好题
    Codeforces Round #440(Div.2)
    Codeforces Round #439 (Div. 2)
  • 原文地址:https://www.cnblogs.com/jldiary/p/11686905.html
Copyright © 2011-2022 走看看