You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Breaking ChangeWould introduce errors in existing codeBugA bug in TypeScriptDomain: lib.d.tsThe issue relates to the different libraries shipped with TypeScriptFixedA PR has been merged for this issue
I was just following the model which was already there.
That is, all event handlers are declared as returning any.
Therefore if we change 1 of them to void, all of the rest gotta follow suit as well.
However, any "onEventType" handler callback can indeed return false in most cases as replacement for preventDefault() method or ev.returnValue = false.
Therefore I believe most correct returning type is boolean. Or at least void | boolean.
Breaking ChangeWould introduce errors in existing codeBugA bug in TypeScriptDomain: lib.d.tsThe issue relates to the different libraries shipped with TypeScriptFixedA PR has been merged for this issue
Activity
mhegazy commentedon Nov 19, 2015
PRs are welcomed. Here is some information about contributing lib.d.ts fixes: https://github.com/Microsoft/TypeScript/blob/master/CONTRIBUTING.md#contributing-libdts-fixes
DanielRosenwasser commentedon Feb 3, 2016
I think those should return
voidGoToLoop commentedon Feb 3, 2016
any.void, all of the rest gotta follow suit as well.falsein most cases as replacement for preventDefault() method orev.returnValue = false.boolean. Or at leastvoid | boolean.http://www.QuirksMode.org/js/events_early.html