Hacker News new | ask | show | jobs
by dlbucci 4052 days ago
"There is no "document.createElement" in the Javascript spec." Uh... https://developer.mozilla.org/en-US/docs/Web/API/Document/cr...
3 comments

Yes, document.createElement exists and is documented. But check the links at the bottom of the page: the function comes from the DOM and HTML5 specs, not from the Javascript spec.
Your link actually shows it's not part of the EMCAScript specification :)

No worries just a common misconception; the DOM API is part of HTML and DOM specifications.

Yeah well , this IS the ecmascript AKA javascript spec :

https://es5.github.io/

you pointed to a mozilla wiki which has a entry under "web" directory

     >"There is no "document.createElement" in the Javascript spec." Uh... https://developer.mozilla.org/en-US/docs/Web/API/Document/cr...
well, I hope you learned something today because your link isn't the javascript spec.