# web-small-example **Repository Path**: luoriwusheng/web-small-example ## Basic Information - **Project Name**: web-small-example - **Description**: 案例锦集 - **Primary Language**: JavaScript - **License**: Not specified - **Default Branch**: master - **Homepage**: https://gitee.com/luoriwusheng/web-small-example - **GVP Project**: No ## Statistics - **Stars**: 1 - **Forks**: 0 - **Created**: 2021-07-22 - **Last Updated**: 2025-04-16 ## Categories & Tags **Categories**: Uncategorized **Tags**: vue2 ## README # web-small-example > 当前项目基于 vue-cli3 搭建, 语法是 vue2 ### 案例 - [x] element-ui 表单校验 - [x] el-table 表格输入附带校验 - [x] el-form 表单的统一动态字段校验, 以及清除文件上传以后,warning还存在的问题 - [x] 动态遍历的input 聚焦focus - [x] vue项目使用图片的 3种方式 - [ ] vue 跨多级组件(3+),深层数据, 最底层组件数据不更新问题 - [ ] 好用的指令集合 v- - [ ] element-ui 图片上传组件动态el-input组件结合 - [ ] 通过路由表动态实现面包屑导航 - [ ] 基于element-ui 实现 查询页面头部字段过多 提供 展开收起功能 - [x] vue.extend 说明 - [x] vue的异步组件 - [x] element-ui 动态表头 - [x] element-ui 表格合并 - [x] event-bus 实现 ### 注意事项 less版本默认为 "less": "^4.1.1", 对应的 less-loader 应该安装 7.X 版本, 默认是9.x 版本, 不兼容 ### 报错解决 - 遇到 error Promise executor functions should not be async no-async-promise-executor > 在package.json中 eslintConfig.rules 添加 "no-async-promise-executor": 0 ```javascript { checkFields () { return new Promise(async ((resolve, reject) => { try { // 这个位置 就会报上面的错误 const res = await this.$refs['child'].validate() resolve(res) } catch (e) { reject(e) } }) }, } ```