π» Programming
100 JavaScript Quiz Questions & Answers 2026
JavaScript fundamentals, ES6, React, Node.js, TypeScript and modern JS concepts
Ready to test your knowledge?
Take the Quiz β
JavaScript Basics β 25 Questions
- Who created JavaScript? (Brendan Eich β created in 10 days in 1995 at Netscape)
- What is JavaScript's official name? (ECMAScript β JavaScript is the brand name)
- What does "use strict" do? (Enables strict mode β catches common coding mistakes)
- What is the difference between var, let, and const? (var = function-scoped, hoisted; let = block-scoped; const = block-scoped, immutable binding)
- What are JavaScript data types? (string, number, boolean, null, undefined, object, symbol, bigint)
- What is null vs undefined? (null = intentional empty value; undefined = variable declared but not assigned)
- What is type coercion? (Automatic conversion of data types β "5" + 3 = "53")
- What is === vs ==? (=== checks value AND type; == only checks value with coercion)
- What is a closure? (Function with access to its outer scope even after outer function returns)
- What is hoisting? (Variable/function declarations moved to top of scope before execution)
- What is the DOM? (Document Object Model β tree representation of HTML elements)
- How do you select an element in JS? (document.getElementById(), querySelector(), etc.)
- What is an event listener? (element.addEventListener("click", function) β runs function on event)
- What is a callback function? (Function passed as argument to another function)
- What is the difference between synchronous and asynchronous code? (Synchronous blocks execution; asynchronous runs without blocking)
- What is a Promise? (Object representing eventual success or failure of async operation)
- What is async/await? (Syntax for writing async code that looks synchronous)
- What is the event loop? (JS mechanism handling async code in a single thread)
- What is JSON.parse()? (Converts JSON string to JavaScript object)
- What is JSON.stringify()? (Converts JavaScript object to JSON string)
- What is the spread operator (...)? (Expands iterable elements β [...arr1, ...arr2])
- What is destructuring? (Extract values from arrays/objects β const {name} = person)
- What are template literals? (Backtick strings with embedded expressions β `Hello ${name}`)
- What is an arrow function? (const fn = () => expression β shorter function syntax)
- What is a prototype? (Every JS object has a prototype β basis of JS inheritance)
Modern JavaScript & Frameworks β 25 Questions
- What is Node.js? (JavaScript runtime built on Chrome's V8 engine β runs JS outside browser)
- What is npm? (Node Package Manager β manages JavaScript dependencies)
- What is React? (Meta's UI library for building component-based interfaces)
- What is Vue.js? (Progressive JavaScript framework for building UIs)
- What is Angular? (Google's full-featured TypeScript framework for SPAs)
- What is TypeScript? (Superset of JavaScript with static typing)
- What is Next.js? (React framework for server-side rendering and full-stack apps)
- What is a Single Page Application (SPA)? (Web app loading single HTML page and updating dynamically)
- What is state in React? (Data that changes over time and triggers re-renders)
- What is a React hook? (Function starting with "use" β useState, useEffect, etc.)
- What is Redux? (State management library for JavaScript apps)
- What is Webpack? (Module bundler for JavaScript applications)
- What is Babel? (Transpiler converting modern JS to browser-compatible code)
- What is REST vs GraphQL? (REST: fixed endpoints; GraphQL: flexible queries)
- What is Express.js? (Minimal Node.js web framework)
β Frequently Asked Questions
Why is JavaScript the most important web language?
JavaScript is the only programming language that runs natively in web browsers, making it essential for front-end development. It also runs on servers (Node.js), mobile (React Native), and desktop apps (Electron).
What is the difference between JavaScript and Java?
Despite the name similarity, they are completely different languages. Java is compiled, statically typed, and used for enterprise/Android. JavaScript is interpreted, dynamically typed, and used for web.
π― Practice Quizzes β Programming
Ready to test what you learned? Pick a quiz below and challenge yourself:
Ready to Test Your Programming Knowledge?
Take our Programming quiz and see how you rank against players worldwide!