React js project in Hindi # Protected Routes
Вставка
- Опубліковано 10 січ 2021
- in this react js project we learn how to integration for sign up in react js project from scratch. This video is made by anil Sidhu in the Hindi language
Protected Routes
Hide Login and Register Page after Register
Make Protected Route
Redirect Login and Register Page
Redirect Product Page
Test Complete Flow
This was amazing, very simple, and easy to understand even for a beginner. Thanks a ton. Subscribed!
Sir g.... awesome video....I m watching others video's for two days nothing helped me out. But your video really explain the basics 👌👌
Sir very nice sir
nice bro
Anil you can say or you want explain ACL. which is operate by Routes.
Only because of one missing video of laravel api i am getting stucked in every video..u must have explained how did u make ecomm backend....very much upset😭
is there not any other way to make a protected route ? I mean Why would you use the local storage to hide/redirect things?
what if someone manually put sth in the local storage as everyone does have the Option to edit the values ??
then those conditions that you put to hide the navlinks and redirection of the user would be failed automatically.
and could also lead to a security loop hole, don't you think?
yaar bhaiya Redux pr jldi video banao, maine aapki pehli wali serise bhi dekhi hai leki jyda kuch smjh me nahi aaya, or bhi search ki hai youtube pr to nahi smjh me aarha
please jldi se jldi ek project laiye.
thank you
nice
Please useContext forget data drilling and save unwanted components render.
Sir when I run the protected route it sowing export create (import as 'createPath' ) not found in react- router errors
Sir, localstorage.getItem krne pr koi bhi key value ni aa rahi after successful registration , can you plz tell me kya error ho skti hai ?
Bhai Protected.js me function ka Naam "Login" rkhe ho & jsx file ko direct props se pull kr liye. Jabki same follow kr rha mai mere ko bhar bhar ke error aya, Fir pta chala jsx ko direct as varibale use n kr skte To mai aise likha esko:
let Cmp = () =>{
return ;
};
Now, its fine.
People using router version 6 might get errors. So to avoid it follow the code below.
I tried same but getting error
@@umairali2360 don't need to do make protected component.Just go to those routes wherever you want to protect make sure there check {! localStorage.getItem('key') ? return navigate("/path") : null }
@@umairali2360 check how the props is being passed it should be in brackets
Sir isme if me wrong details dalta hu to bhi page redirect ho jata h or sahi b dalu to localStorage m b jata h wrong detail se kese handle krre sir
Jaise mene galat detail or login button pr click to add page par ja rha h ye condition kese chek kru please reply me sir
role bassed access control routing pr koi video banayn
Hello sir
I am not able to use react router hook .
In my code bcz its showing,
useHistory is not founded in react router so how can i use
Sir, where is English series for this? Are you teaching for Indians only :( but I think most of the Indians also understand English while we don't understand Hindi. :(
Thank you
dear in version 6 not props working and no error but not working plz reply me as soon thanks
Bro ya protection secure hay like laravel auth system?
Sir, please make a sequence of all the videos so that we access them easily.
Sure, I will make a playlist for this soon
@@codestepbystep sir please mention the serial no. on all series video
When I am trying to protect getting error like
A Route is only ever to be used as the child of Routes element, never render directly. Please wrap your Route in a Routes. Plz plz give me the solution
Bhai login and register with redux ki videos banao please bhai 🙏 request hai bhai 🙏😞
sir protected Component use krne ke baad error aara hai pls reply sir ('Check the render method of `Protected`.')
sir pls reply
sir please git ka link jarur diya karo code ka
plzz provide the playlist link
You called useEffect conditionally. It gives error
I am using router 6 still getting error, please respond
what error u r getting
umairali bahi how to resolved this problem i am also use versin 6
Sir git hub ka link dijiye yeh video ka
sir where is next video
What if user add manully in local storage (user-info) will that user be logged in (But the user isn't register in database)
not logged
@@aghazjunaid2235 how do you make that
too Weak Protected Routes security it should not fully depend on local storage
Security should not depend on frontend
Y history.push wala tareeka mujhe sahi nhi laga kyunki Maan lo 10 pages h to kya 10 p esa krna padega 🥲😅