Skip to content

Bug: Nested setState and unstable_batchedUpdates (are they ignored?) #17970

@salvoravida

Description

@salvoravida

Nested setState and unstable_batchedUpdates (are them ignored?)

React version: 16.12

Steps To Reproduce

https://codesandbox.io/s/batchedupdates-uselayouteffect-evj8s

open profile after click, you will see 3 commit.

it seems that even if we use unstable_batchedUpdates, nested setStates called on
didUpdate/layouteffect do not get batched.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions