React deep dive:
What is React Hook? What is useState? What is React`s reconciliation algorithm and how does it work?
Tell me about state management solution (Context, Redux)
If you were given a task to implement state management solution, how would you do it?
Is this a good solution?
function GlobalState() {
let val;
const setVal = (value) => {
val = value;
};
const getVal = () => {
return val;
};
return { setVal, getVal };
}