How to create an object without prototype? | JavaScript Interview Question | Beginner
@Devtools Tech

In this question, you need to create an object called devtools that should not have a prototype.

const devtools = // write object creation mechanism

console.log(devtools.constructor); // undefined
console.log(devtools.__proto__); // undefined
console.log(devtools.constructor.prototype); // Error
console.log(devtools.toString()); // Error

Write your solution and test it against our test cases.

Loading IDE...