You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
functionApp(){const[count,setCount]=useState(0);return(<><buttononClick={()=>setCount((count)=>count+1)}>{count}</button><divdangerouslySetInnerHTML={{__html: "I should only paint once"}}/></>);}
Clicking the button should not trigger a repaint of "I should only paint once". This works as expected in react@18.3.1 but not in react@19.0.0-rc.1 or react@0.0.0-experimental-5b0ef217-20241202.
Browser: Chrome Version 131.0.6778.86 (Official Build) (arm64)
Summary
Given the following component
Clicking the button should not trigger a repaint of "I should only paint once". This works as expected in react@18.3.1 but not in react@19.0.0-rc.1 or react@0.0.0-experimental-5b0ef217-20241202.
react@18.3.1
Screen.Recording.2024-12-03.at.13.16.43.mov
react@0.0.0-experimental-5b0ef217-20241202
Screen.Recording.2024-12-03.at.13.17.50.mov
Source Code
The text was updated successfully, but these errors were encountered: