SetState перед функцией реагирует
this.setState(
{newState: 'whatever'},
() => {/*do something after the state has been updated*/}
)
Xenophobic Xenomorph
this.setState(
{newState: 'whatever'},
() => {/*do something after the state has been updated*/}
)