var a = document.*!*createElement( "div" )*/!*; Element.prototype.testNewProto = function() { alert( 'lalalalalala' ) } a.testNewProto();