React. useRef hook

UseRef hook features and use cases

UseRef hook characteristics

Image for post
Image for post
Image for post
Image for post

Forwarding refs

Image for post
Image for post
Image for post
Image for post

useRef. Storing mutable information

const value = useRef('foo');value.current = 'bar';
Image for post
Image for post
Messages enqued: 1 (valor the count en el instante N-2)
Messages enqued: 2 (valor the count en el instante N-1)
Messages enqued: 3 (valor the count en el instante N)

Final thoughts

Entre paseo y paseo con Simba desarrollo en Symfony y React

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store