javascript - Is it a bad idea to modify Event.prototype for cross-browser event.preventDefault();? -
pretty straightforward question. < ie8 doesn't support event.preventdefault()
, i'd modify event.prototype
ie add own preventdefault
method utilizing event.returnvalue
. simple task, bad idea?
so far, in opinion, best answer question it's not bad idea. doesn't mean screwing around prototype in general or other methods of event
idea, normalizing event.preventdefault()
seems entirely harmless– no, helpful.
please chime in if can provide better answer.
Comments
Post a Comment