Strict Mode Explained
The opt-in stricter variant of JavaScript that catches silent errors, disables risky features, and is the default inside ES modules and classes.
Strict mode is an opt-in mode, enabled with the string 'use strict' at the top of a file or function, that changes JavaScript's behavior to catch mistakes that would otherwise fail silently, throw more helpful errors, and disable a handful of features considered unsafe or confusing. It's a smaller topic than closures or the event loop, but interviewers use it to check whether you know what modern defaults actually are.
Sloppy mode is like a lenient proofreader who silently 'fixes' your typos without telling you; strict mode is an editor who stops and flags every mistake immediately so you actually learn about it instead of shipping it.