React's usetState has an eagerState optimization, duplicate rendering is not triggered when I set the same value repeatedly
but is there a similar optimization for this.setState of class components? even if I do this.setState({count: 1}) in the class component every time, it still renders repeatedly
here is the online code: https://codesandbox.io/s/zealous-panka-wonxfy?file=/src/App.js