CONTACT US

    useEffect vs useLayoutEffect

    • useLayoutEffect: If you need to mutate the DOM and/or DO need to perform measurements
    • useEffect: If you don’t need to interact with the DOM at all or your DOM changes are unobservable.

     

    Article link copied

    Close button