React Version
React versions matter because APIs changed. Class components were the default for years. Hooks arrived in 16.8. React 18 added createRoot and concurrent rendering. In a viva, say the era you write: function components + hooks, React 18+ createRoot — not ReactDOM.render.
Don’t mug a patch like 18.2.0 as if it were history. Check package.json on a real project. react and react-dom should share the same major. Mixing 17 and 18 is a support headache.
React Version — output — three era lines. Interview wants 18+ createRoot, not a random patch.
Exam tip
Hooks era + createRoot. Check package.json.