DEV Community

Cover image for Popular JavaScript Interview Questions
Hidayt Rahman
Hidayt Rahman

Posted on • Edited on

2 1

Popular JavaScript Interview Questions

Basic Questions

DOM Questions

  • How to select all element using class?
  • What querySelector() returns?
  • How to find an element in the tree?
  • How to select top most parent element?
  • How to select next element?
  • How to remove element?
  • How to add attribute?
  • How to select a data attribute?
  • How to set value on the data attribute?
  • How to apply style on element?
  • How to wait until an element exists? A R

Popular Questions

  • What is closure?
  • What is hoisting?
  • What is Higher Order Function?
  • What is Pure Function? A
  • What is Recursion?
  • Where we should use Recursion?
  • What is reduce function?
  • What is map function?
  • What is filter function?
  • Difference between == and ===?
  • What is the difference between call, apply and bind?
  • What is the difference between map and forEach
  • What is the difference between rest parameter and spread operator A1
  • Difference between Promise vs Async Await A

Basic DS and Algo

  • Calculate the functional arguments?
  • Find the largest number?
  • Return the unique numbers from the array?
  • Return the duplicate numbers from the array?
  • Return the count of duplicate numbers from the array?
  • Find the falsy values and return them?
  • compare two arrays and returns true if both are same.
  • compare two objects and return true if both are same.
  • return flat array from the multi dimensional zig-zag array?
  • Return truthy item from the array?
  • Return falsy item from the array?

Advance Questions

  • What is function Curry?
  • How and where we can use function curry?
  • What is Debounce in JavaScript?
  • What is throttling in JavaScript?
  • Difference between throttling and debouncing?
  • What is event capturing and how do we use?
  • What is event bubbling and how do we use?
  • What is event delegation and how do we use?
  • Is JavaScript multi-thread?
  • What is Call Stack?
  • What is Event Queue?
  • What is Event Loop?
  • How event loop works?
  • What is temporal dead zone? A1 A2
  • What is Shadow DOM?
  • What is Web Component?
  • What is the difference between shadow and virtual DOM?

Save this article, I will update it regularly :)

SurveyJS custom survey software

JavaScript UI Libraries for Surveys and Forms

SurveyJS lets you build a JSON-based form management system that integrates with any backend, giving you full control over your data and no user limits. Includes support for custom question types, skip logic, integrated CCS editor, PDF export, real-time analytics & more.

Learn more

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs