Refs in React: from access to DOM to imperative API

Developer Way
Developer Way
3.8 هزار بار بازدید - پارسال - 👉 Advanced React Book:
👉 Advanced React Book: https://www.advanced-react.com
👉 Refs in React: from access to DOM to imperative API: https://www.developerway.com/posts/re...

💬 Twitter: Twitter: adevnadia
💬 Linkedin: LinkedIn: adevnadia

👩🏼‍💻  Simple ref use: https://codesandbox.io/s/giant-form-r...
👩🏼‍💻  Pass ref as a prop: https://codesandbox.io/s/example2-pas...
👩🏼‍💻  Pass ref with forwardRef: https://codesandbox.io/s/example3-pas...
👩🏼‍💻  Imperative API with useImperativeAPI hook: https://codesandbox.io/s/example4-imp...
👩🏼‍💻   Imperative API without that useImperativeAPI hook: https://codesandbox.io/s/example5-imp...

Looking into why we need access to DOM in React, how Refs can help with that, what are useRef, forwardRef and useImperativeHandle hooks, and how to use them properly.

#react #reactjs #webdevelopment #programming #frontend #frontenddeveloper #js #javascript
پارسال در تاریخ 1402/01/08 منتشر شده است.
3,838 بـار بازدید شده
... بیشتر