What happens If I pass string type for getPrototype method?

Posted by Jennifer | Updated on

In ES5, it will throw a TypeError exception if the obj parameter isn’t an object. Whereas in ES2015, the parameter will be coerced to an Object.

If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.

Related Questions & Answers