Interview Hub
Sign in

Q5: What is the prototype chain?

MidJavaScript 29

Answer

Each object may delegate property lookups to its prototype (Object.getPrototypeOf). That prototype may have its own prototype, forming a chain until null. class syntax is syntactic sugar over prototype-based inheritance. hasOwnProperty distinguishes own vs inherited properties.

Having a tech or coding interview? Check 29 JavaScript & Node.js interview questions.

EditorJavaScript · local only