交互与动画

交互与动画

1
export default class LeashedOne extends React.Component {
2
constructor(props) {
3
super(props);
4
this.onChange = this.onChange.bind(this);
5
this.onChangeDebounce = _.debounce(
6
value => this.props.onChange(value),
7
300
8
);
9
}
10
onChange(e) {
11
this.onChangeDebounce(e.target.value);
12
}
13
render() {
14
return <input onChange={this.onChange} />;
15
}
16
}
Copied!

页面帧率 FPS

重渲染策略

Last modified 2yr ago