{"slug": "30-technical-interview-questions-explained-the-way-you-d-actually-say-them", "title": "30 technical interview questions, explained the way you'd actually say them", "summary": "A developer compiled 30 technical interview questions across JavaScript, React, and Node.js, with answers written in conversational language to help candidates explain concepts clearly under pressure. The guide covers topics like closures, event loop, hoisting, and React hooks, emphasizing practical verbal explanations over textbook definitions.", "body_md": "Most interview prep content gives you a definition. Real interviews test\n\nsomething different: can you explain your reasoning clearly, out loud,\n\nunder a little pressure — not just recite the right words.\n\nI put together 30 questions across JavaScript, React, and Node.js. Every\n\nanswer here is written the way you'd actually say it in an interview, not\n\nthe way a textbook would write it.\n\n**How to actually use this:** cover the answer, try explaining it out\n\nloud in under 30 seconds, *then* read the answer. If you froze or\n\nrambled, that's the real signal — more than whether you technically knew\n\nthe concept.\n\nA closure is a function that remembers the variables from where it was\n\ncreated, even after that outer function has finished running. It powers\n\nprivate variables, debouncing, memoization, and module patterns.\n\n`setTimeout(fn, 0)`\n\nvs `Promise.then()`\n\n— which runs first?\nThe Promise wins. `.then()`\n\ncallbacks go into the microtask queue, which\n\nfully drains before the next macrotask (like `setTimeout`\n\n) runs — even\n\nwith a 0ms delay.\n\n`var`\n\nbreak inside loops with closures, but `let`\n\ndoesn't?\n`var`\n\nis function-scoped — every iteration shares the same variable.\n\n`let`\n\nis block-scoped, so each iteration gets its own fresh binding.\n\n`==`\n\nactually give you a different (and wrong) answer than `===`\n\n?\n`==`\n\ndoes type coercion first — `0 == false`\n\nand `'' == 0`\n\nare both\n\ntrue. `===`\n\ncompares type and value directly, no surprises.\n\n`this`\n\nbreak in callbacks with regular functions, but not arrow functions?\nRegular functions get `this`\n\nbased on how they're called. Arrow\n\nfunctions inherit `this`\n\nlexically from where they were defined, so it\n\nstays consistent no matter how they're invoked.\n\nJS walks the prototype chain — the object, then its prototype, then\n\nthat prototype's prototype — until it's found or it hits `null`\n\n.\n\nSearch wants **debounce** — fire once after typing stops. Scroll wants\n\n**throttle** — fire at a steady max rate continuously.\n\n`Promise.all`\n\nvs `Promise.race`\n\n?\nUse `all`\n\nwhen you need every result, and it should reject if any fail.\n\nUse `race`\n\nwhen you only care about whichever resolves first.\n\nFunction declarations fully hoist. `const fn = () => {}`\n\nonly hoists\n\nthe declaration, not the assignment, so calling it early throws.\n\nCurrying transforms `f(a,b,c)`\n\ninto `f(a)(b)(c)`\n\n. It's useful for\n\ncreating reusable, partially-configured functions.\n\nReact batches changes, diffs the old and new virtual trees, and only\n\ntouches the specific real DOM nodes that actually changed.\n\n`useEffect`\n\ncompletely?\nThe effect runs after every single render — a common source of\n\ninfinite loops if the effect itself updates state.\n\n`setState`\n\n3 times in one event handler — does React re-render 3 times?\nNo. React batches updates within the same handler into a single\n\nre-render, and React 18 extends this batching further.\n\n`key`\n\nbreak things when a list reorders?\nReact matches elements between renders by `key`\n\n. Using the index means\n\nReact thinks the item *at that position* changed, not that it moved.\n\nA controlled input's value lives in React state and updates via\n\n`onChange`\n\n. An uncontrolled input's value is managed by the DOM itself,\n\nread via a `ref`\n\nwhen needed.\n\n`useMemo`\n\nvs. `useCallback`\n\n— what's the actual difference in what gets memoized?\n`useMemo`\n\nmemoizes a computed value. `useCallback`\n\nmemoizes the\n\nfunction itself — useful for stable references passed to memoized\n\nchildren.\n\nContext re-renders every consumer on any value change — bad for\n\nfrequently-changing state. It's best for rarely-changing global data\n\nlike theme or auth.\n\n`React.memo`\n\n, but it's still re-rendering every time. Why?\n`React.memo`\n\ndoes a shallow prop comparison. A new object, array, or\n\nfunction reference each render looks different even if the underlying\n\ndata is the same.\n\nA function whose name starts with `use`\n\nand that calls other hooks\n\ninside it. The naming convention is how React's linter enforces the\n\nrules of hooks.\n\n`try/catch`\n\nwork for catching rendering errors in React?\n`try/catch`\n\nonly catches synchronous errors in code you directly run.\n\nError Boundaries hook into React's own lifecycle to catch errors during\n\nrendering.\n\nJavaScript execution is single-threaded, but I/O operations get\n\ndelegated to a thread pool. The event loop picks up completed I/O and\n\nruns the callbacks, never blocking on the wait.\n\nReading the whole file into memory holds it all in RAM per request.\n\nStreams process and send data in small chunks, keeping memory usage\n\nflat regardless of file size.\n\n`next()`\n\nactually do in Express middleware, and what breaks if you forget it?\nIt passes control to the next handler in the chain. Forget it, and the\n\nrequest just hangs forever with no response ever sent.\n\nNot easily. JWTs are stateless, so you'd need extra infrastructure like\n\na blocklist or short expiry with refresh tokens to revoke one early.\n\nIt lets asynchronous code read top-to-bottom like synchronous code,\n\nwith normal `try/catch`\n\nfor errors — much easier to reason about than\n\nchained callbacks.\n\nThe `cluster`\n\nmodule forks multiple copies of the process across\n\ncores, sharing the same port, so incoming requests get distributed\n\nacross the workers.\n\n`.env`\n\nfile to Git a serious mistake, not just messy?\nIt usually holds real secrets. Once committed, it's in the Git history\n\npermanently — deleting the file later doesn't remove the old commits.\n\n`GET`\n\nto delete a resource, even if it technically works?\n`GET`\n\nis supposed to be safe and idempotent. Browsers and crawlers can\n\npre-fetch `GET`\n\nURLs, which could accidentally trigger a deletion.\n\nExpress checks a function's parameter count to identify it as an error\n\nhandler. A 4-argument signature is specifically what signals that role.\n\n`package.json`\n\n, same `npm install`\n\n— can two people end up with different dependency versions?\nYes, without a `package-lock.json`\n\n. Version ranges can resolve\n\ndifferently over time, and the lockfile pins exact versions for\n\nreproducible installs.\n\nReading an answer and being able to say it clearly under pressure are\n\ntwo different skills. I've been building [Sparlog](https://sparlog.com)\n\n— an AI that actually interviews you: you explain your reasoning out\n\nloud while writing code, and it scores clarity and correctness\n\ntogether, the way a real interviewer would.\n\nIt's free to try, currently in open beta. Would genuinely love feedback\n\nif you give it a shot.\n\nAlso made a free downloadable PDF version of this list if you'd rather\n\nhave it offline: [sparlog.com/resources](https://sparlog.com/resources)", "url": "https://wpnews.pro/news/30-technical-interview-questions-explained-the-way-you-d-actually-say-them", "canonical_source": "https://dev.to/ramana_babu_c787073206bef/30-technical-interview-questions-explained-the-way-youd-actually-say-them-4a3g", "published_at": "2026-08-03 03:05:35+00:00", "updated_at": "2026-08-03 03:38:41.954973+00:00", "lang": "en", "topics": ["developer-tools"], "entities": ["JavaScript", "React", "Node.js"], "alternates": {"html": "https://wpnews.pro/news/30-technical-interview-questions-explained-the-way-you-d-actually-say-them", "markdown": "https://wpnews.pro/news/30-technical-interview-questions-explained-the-way-you-d-actually-say-them.md", "text": "https://wpnews.pro/news/30-technical-interview-questions-explained-the-way-you-d-actually-say-them.txt", "jsonld": "https://wpnews.pro/news/30-technical-interview-questions-explained-the-way-you-d-actually-say-them.jsonld"}}