React-Knowledgeable

Latest Video

When updating HTML content and sticky status at the same time in a macrotask/microtask (e.g. setTimeout or Promise.then), the value shown on the screen seems to be stale value. (still 0)

Code sandbox: https://codesandbox.io/s/adoring-bose-z9uep To replicate the issue, open this link in Safari: https://z9uep.csb.app/ (a popped out version of the sandbox above)

What I learned about this issue so far:

- moving setState into main thread would solve the issue
- changing position: sticky; to position: fixed; will solve the issue
- not using the condition operator ? : will solve the issue

All Videos (37)
RK #63 - "CSS"
Saturday, 22 February 2020
(Ec)static Commerce
Thursday, 5 December 2019
Writing a Gatsby plugin
Thursday, 5 December 2019
React Knowledgeable
Friday, 29 November 2019