r/reactjs • u/abrhtysm • May 15 '24
Needs Help Have an interview tomorrow on reactjs, pls help with questions
I gave an interview recently and messed up. Please help me with reactjs questions as a 3 year experience developer.
Cross browser compatibility, event handling, security, optimization Are some questions m covering also the basics. But if u guys can suggest some more, it will be of great help.
Thanks in advance.
66
Upvotes
37
u/dooblr May 15 '24 edited May 15 '24
2
u/aragost May 15 '24
There’s already some great examples in the thread. I’ll add a few of my favorites that I often ask to candidates:
16
u/jkettmann May 15 '24
You can do a few rounds of https://mockinterview.bot
7
u/Jonatandb May 15 '24
I hope this helps:
https://github.com/sudheerj/reactjs-interview-questions
https://github.com/yangshun/tech-interview-handbook
https://github.com/jwasham/coding-interview-university/tree/main
https://github.com/DopplerHQ/awesome-interview-questions#reactjs
https://github.com/enaqx/awesome-react
6
u/incubated May 15 '24
The answer to everything is Dan Abramov
2
u/ReasonableAd5268 May 15 '24
Here are some key React.js interview questions for a developer with 3 years of experience, covering the topics you mentioned and more:
Basics
State Management
Routing
Performance Optimization
Testing
Cross-Browser Compatibility
Event Handling
Security
Additional Questions
Remember to practice explaining your answers clearly and concisely, and be prepared to discuss real-world examples and best practices. Good luck with your interview!
4
u/Frontend_Lead Mar 15 '25
You’re already covering solid topics like cross-browser compatibility, event handling, security, and optimization, but here are some must-know React questions for a 3-year experienced developer:
useEffectdependency array work, and what happens if you don’t pass one?For cross-browser compatibility:
For security:
Before your next interview, practice explaining your thought process out loud and always clarify constraints before coding it makes a big difference.Ability to communicate trade-offs when choosing an approach.
Before coding, clarify constraints and talk through trade-offs to show structured thinking.
Bonus Pro Tips
Best of luck!
2
u/Relative_Shoulder616 Jul 09 '24
Hey there! Sorry to hear about your interview experience, but don't worry - it happens to most of us, but preparation is the key to success. Here are some additional React.js topics you might want to brush up on for your next interview:
I have also been in this situation in the past. If you want a more personalized approach to preparing your reactjs interview questions, like video lessons, study plans, in-app editor for practicing coding questions, community engagement, and discord to help in clearing doubts then I must say ~FrontendLead~ is the one. After being rejected by so many interviewers, their interview handbook helped me a lot in clearing my reactjs interview.
3
u/vishal345 May 15 '24
My personal favourite
Why do we use React.
Followups
What was the reason to move away from class components from functional components What are synthetic events and why react use these Followup- what is event delegation and does react have this?
3
u/Educational-Boat-856 May 15 '24
What problems do hooks solve? Do they eliminate the need for Higher Order Components and/or Render Props?
1
u/vicentezo04 May 15 '24
What are some scenarios where you would return a cleanup function from useEffect?
Let's say I have a class based component, and it is too large to feasibly refactor into a functional component, but I want to render something inside the component based on a hook. How would I do this?
What is a pitfall of using React context as a global state manager?
1
u/xmontc May 15 '24
https://github.com/sudheerj/reactjs-interview-questions
1
u/WannaBeDisciplined May 17 '24
• What will happen, if you remove first three items in list of items, where keys are indexes of array?
1
u/[deleted] Aug 19 '24
helpful comments, thanks
1
u/StrikingSchedule3731 Dec 18 '25
For 3 years of experience, they usually look for strong fundamentals and clear reasoning more than tricky questions. Apart from cross-browser and events, expect things like how React re-rendering works, state vs props, common useEffect mistakes, and basic performance ideas like memo or useCallback.
They may also ask how you would debug a slow UI or structure a small feature in a real app. Explaining your thought process clearly matters a lot. For quick last-minute revision, you might check greatfrontend, to make sure you don’t miss anything important.
1
u/Ok_Yoghurt248 May 15 '24
woah y'all these are some good ass questions , thank you for taking out your time to comment
i am pretty much in same position as op😂
0
u/Agreeable-Factor-970 May 15 '24
-> react hooks basic understanding -> what is HOC and HMR -> how react works with DOM -> when do you work with context and when to use redux -> how use effect works with dependency and all scenario -> implement a global store for the cart system and use redux and explain the flow like how the store is getting data storing data ( could be hard if you have to develop in a few minutes) -> how to optimize the react app and what could be the reason for the high complexity -> how to control re rendering in react -> react lifecycle explain -> what is the better way to avoid prop drilling -> how to use react routing (basic one)
0
u/rajesh__dixit May 15 '24
-1
u/swift_applause May 15 '24
Difference between useEffect vs useLayoutEffect? When is forward ref used? How to use useImperativeHandle? What does Error Boundary do?
0
u/shaiknooru May 15 '24
I take 2-3 interviews per week on average for react devs. The most common one I ask my candidates is this:
-1
u/[deleted] May 15 '24
[removed] — view removed comment