Last active
January 28, 2023 15:33
-
-
Save ajhsu/d89e4bbf827fbd4b42f9ab2e3cd70e4b to your computer and use it in GitHub Desktop.
document.createElement proxy function
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var __createElement__ = document.createElement; | |
document.createElement = function(tagName, options){ | |
console.log(`Element <${tagName}> created.`); | |
return __createElement__.call(this, tagName, options); | |
}; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment