By any chance if you are looking for any javascript concepts, please go through the following links.
I have attended many interviews when transitioning from one company to other company. There are set of common react questions that are asked in the interviews on L1/base/beginner/foundation level , you are expected to answer them in the initial stage of screening.
Following are the questions that I was asked during my interviews but going through these or mugging up these question and answers DOESN’T make you a “developer”. So, I haven’t posted any sort of answer down here.
Go through them understand the concepts, play with the code, become a developer and crack the interviews.
There is no particular order that I am writing. So, please go through all of them.
React interview questions 2022
- What is DOM and how are they different from eachother?
- What are synthetic events in React?
- Lifecycle of a React component and it’s phases
- React hooks like useState, useReducer, useEffect, useRef, useLayoutEffect, and useMemo.
- Why there was a need to introduce the hooks in the react and how are things handled before introducing the hooks?
- What are lifecycle methods in the class component?
- React Memo
- What are difference between Memo and useMemo?
- How to prevent child component from re-rendering when there is no change in the child component in react?
- What is useImperativeHandle and useCallback?
- What is the order in which hooks are called? mainly useLayoutEffect and useEffect.
- What is pros and cons of using arrow functions?
- What are error boundaries?
- What are custom hooks and their rules? In which case we need to go with custom hook?
- What are High Order Component and what is the use case of it?
- In how many ways can we style in react?
- Optimizing techniques in React.
- How to pass data between parent and child and sibling components
- What is redux and what pattern does it follow?
- What are the other patterns and other alternatives for the redux?
- What is middleware and their use cases?
- How to perform async actions in redux?
Going further, I will also be writing on the vue and CSS combined.
Please let me know classic questions that I missed but asked in your interviews.