When to useLayoutEffect Instead of useEffect

added by JavaScript Kicks
9/23/2019 7:28:33 AM

1553 Views

There are two React hooks, useEffect and useLayoutEffect, that appear to work pretty much the same. The way you call them even looks the same. But they're not quite the same. Read on for what makes them different and when to use each.


0 comments