摘要:
在写react组件的时候,会有这个警告 Can't perform a React state update on an unmounted component. This is a no-op, but it indicates a memory leak in your application. 阅读全文
posted @ 2020-07-20 19:42
小魏code
阅读(3032)
评论(0)
推荐(0)
摘要:
import React,{Component } from 'react' import './App.css'; class App extends Component{ scrollToBottom() { if (this.messagesEnd) { const scrollHeight 阅读全文
posted @ 2020-07-20 18:47
小魏code
阅读(3539)
评论(0)
推荐(0)
摘要:
定义全局变量timer。 this.state = { timer: null, }; // 组件加载完毕 启动定时器 componentDidMount(){ setTimeout(this.iTimer,0); } // 定时器 iTimer = () => { this.setState({ 阅读全文
posted @ 2020-07-20 18:25
小魏code
阅读(4285)
评论(0)
推荐(0)
摘要:
https://blog.csdn.net/SCU_Cindy/article/details/82778031 阅读全文
posted @ 2020-07-20 18:20
小魏code
阅读(170)
评论(0)
推荐(0)
摘要:
//换行white-space:normal;word-break:break-all;word-wrap: break-word; 相关属性white-space: normal|pre|nowrap|pre-wrap|pre-line|inherit; white-space 属性设置如何处理元 阅读全文
posted @ 2020-07-20 17:12
小魏code
阅读(2270)
评论(0)
推荐(0)
摘要:
div 加滚动条bai的方法:<div style="position:absolute; height:400px; overflow:auto"></div>div 设置滚动条显示du:overflow :yesdiv 设置滚动条自适应zhi显示:overflow :autodiv 设置上下滚动 阅读全文
posted @ 2020-07-20 17:10
小魏code
阅读(1098)
评论(0)
推荐(0)
浙公网安备 33010602011771号