useREF HOOK 🪝 REACT Interview Question #shorts #reactjs

preview_player
Показать описание
useRef Hook is used to go outside React World. What does that mean? What we will access outside react world. Check in this video

🤯 Crash Courses (Single Video)

🧑‍🏫 Full Course Playlists

💻 Projects Playlists

🕹 Mini Projects (Single Video)

Рекомендации по теме
Комментарии
Автор



JavaScript Shorts:

React Shorts :

coderdost
Автор

One more point I'd like to add, useRef can be used for storing any value that you might need later on, in class component you can use this.something to access any variable everywhere. but in functional component you can't. so useRef can be used anywhere.
one more point, that in useEffect if you want to know what was the previous state before updating the new state, then only useRef can be used no other way around.

mayankmakwana
Автор

Thanks for this kind of short knowledge videos

hardikluhar
Автор

It is not suggested to directly manipulate Dom in react. React handles all the dom manipulation for you

the_akhleshkumar
Автор

Pls make a video on:
Class components have render method but function components doesn't have render method they return elements. Why?

adarshkhatri
Автор

Bro lakin kch complex projects mai useref dikkat deta hai next js k sath, cross-origin block kar deta hai jab ki cross origin se related kch Kia hi nai hai upar se agar allow bhi kiya meta data mai tho bhi same seen hota hai, aur chat gpt bolta hai browser sandboxing ki waje se hota hai 🤔

ModderorWot-cizj
Автор

What is the best scenario to use useref

anujadi
Автор

Is it compulsory to initialize useRef?
And we do not initialize then what will be the value of current property?
Pls reply

adarshkhatri
Автор

for example hm user sy input lety hein or onchage py sets setState chalaty hein to kya hm useState ki jagha useRef ko use kr payen gy udr???

sulaimanshabbir
Автор

what is the meaning of related to render? didnt get that.

pranavkokate
Автор

Since you know so much about react, I would like to know what you do for a living

manasgupta