window.onresize = () => {
this.setState({ ww: window.innerWidth }); this.build(); this.draw();
}
window.onresize = function() {
if (window.innerHeight >= 820) { /* ... */ }
if (window.innerWidth <= 1280) { /* ... */ }
}