
vue
csdn_meng
这个作者很懒,什么都没留下…
展开
-
Vue+TypeScript+TSX
import {Component, Prop, Vue} from 'vue-property-decorator'import OtherComponent from '@/components/OtherComponent'@Component({ components: {OtherComponent}})export default class Exapmle extends Vue { // data public data1? string; public data2 num原创 2021-04-17 18:14:32 · 403 阅读 · 1 评论 -
element-ui 封装table组件(自动填满父容器高度,固定头部滚动)
写在前面:element-ui的表格组件是常用的组件之一,唯一不太好的是,当页面组件高度由百分比算出来的时候想让头部固定滚动需要另写JavaScript计算,所以将计算封装在了组件里面(el-table-plus),只映射了部分常用的属性,如果需要可以自行映射其他属性<!-- el-table-plus --><template> <div style="height: 100%"> <el-table ref="table" .原创 2020-12-11 11:31:22 · 3950 阅读 · 1 评论 -
vue2-ace-editor自定义语法提示
vue2-ace-editor自定义语法提示前言:网上找了很多不是很系统,这里发一个我自己成功的一个例子代码:<!-- editor --><template> <AceEditor v-model="value" @init="init" :enableBasicAutocompletion="true" :enableLiveAutocompletion="true" :enableSnippets="true"原创 2020-11-26 19:32:18 · 2645 阅读 · 3 评论 -
element-ui表单输入框开启记忆功能
<el-form ref="form" :model="formData" label-width="120px"> <el-form-item prop="item1" label="示例1:" :required="true" error="请输入值" > <!-- name 要和 el-form-item的prop 以及绑定的变量名一致 --> <el-input name="item1" auto-comple原创 2020-06-22 15:43:29 · 18989 阅读 · 15 评论 -
vue封装echars通用组件
<!-- Echar --><template> <div :style="{'width': width, 'height': height}" ref="area"></div></template><script>// 引入 EChartsimport echarts from 'echarts'export default { name: "EChar", props: { /*可以是百分比也可原创 2020-05-27 15:12:29 · 13416 阅读 · 0 评论 -
vue作用域插槽
<!DOCTYPE html><html> <head> <meta charset="UTF-8"> <title>vue 作用域插槽</title> </head> <body> &am原创 2018-08-28 16:30:37 · 11264 阅读 · 0 评论