上一页 1 ··· 61 62 63 64 65 66 67 68 69 ··· 79 下一页
摘要: 一个固定高度的div的子元素 在垂直 方向上平均分布 .important-dec{ height: 121px; flex-direction: column; display: flex; justify-content: space-between; } 动态计算元素的宽 除了支持 - 还有 阅读全文
posted @ 2019-12-02 22:13 南风晚来晚相识 阅读(455) 评论(0) 推荐(0)
摘要: 今天下午在请求接口的时候,出现了一个问题就是 传参问题 接口是请求成功的200,但是修改后返回来的却是500,这就很纳闷怎么会这样了。 经过查找,原来是因为传参问题。将有一个name:0 传递成了name:1; 又是怎么确认是传参的问题了。 不要去写动态传递参数了。写一个死的参数 来测试这个死的参数 阅读全文
posted @ 2019-12-02 21:54 南风晚来晚相识 阅读(521) 评论(0) 推荐(0)
摘要: <template> <div> <el-table :data="tableData" style="width: 100%"> <el-table-column label="日期" width="180"> <template slot-scope="scope"> <i class="el- 阅读全文
posted @ 2019-12-02 21:26 南风晚来晚相识 阅读(4554) 评论(0) 推荐(0)
摘要: 给表头添加一个底部分割线 固定表格的内容高度 添加底部按钮 <template> <div> <el-button type="text" @click="dialogTableVisible = true">打开嵌套表格的 Dialog</el-button> <el-dialog title=" 阅读全文
posted @ 2019-12-01 20:01 南风晚来晚相识 阅读(6714) 评论(0) 推荐(0)
摘要: 17==》循环数组 类似v-for import React, { Component } from "react"; export default class CharShop extends Component { // state初始化一般写在构造器当中 constructor(props){ 阅读全文
posted @ 2019-12-01 17:49 南风晚来晚相识 阅读(3112) 评论(0) 推荐(0)
摘要: 17==》 条件渲染 state初始化一般写在构造器当中 CharShop.js如下 import React, { Component } from "react"; export default class CharShop extends Component { // state初始化一般写在 阅读全文
posted @ 2019-12-01 17:47 南风晚来晚相识 阅读(306) 评论(0) 推荐(0)
摘要: 16==》 this.setStat是批量执行的 它发现做三次是多余的,所以只执行一次 import React, { Component } from "react"; export default class StaTest extends Component { state = { nun: 阅读全文
posted @ 2019-12-01 17:45 南风晚来晚相识 阅读(276) 评论(0) 推荐(0)
摘要: 14 》 修改state中的值 不能够直接修改 state = { num: 10 } 如 this.state.num+=12; 不能够直接修改 错误 通过 this.setState({ num:this.state.num+12 }) 15==> 获取state中的值 ps==>当你进入一个组 阅读全文
posted @ 2019-12-01 17:42 南风晚来晚相识 阅读(1419) 评论(0) 推荐(0)
摘要: componentDidMount声明周期函数 表示组件渲染完成后 componentWillUnmount声明周期函数 组件将要卸载 通常用于(为了防止内存泄漏 清除定时器) 11==>创建组件 Clock.js 组件名大写 12==》报错 Attempted import error: 'Clo 阅读全文
posted @ 2019-12-01 17:38 南风晚来晚相识 阅读(1044) 评论(0) 推荐(0)
摘要: 10 > 传递参数 import React from "react" //一定要导入React // 函数类型去创建组件 export function Web1(props){ return <div> 我是以函数的形式创建的组件 <p> {props.name}</p> </div> } // 阅读全文
posted @ 2019-12-01 17:28 南风晚来晚相识 阅读(209) 评论(0) 推荐(0)
上一页 1 ··· 61 62 63 64 65 66 67 68 69 ··· 79 下一页