when compile typescript project, i'm using noimplicitany
option won't forget specify types on variables , arguments.
however have arguments don't use. example:
jquery.ajaxtransport("+*", function (options: jqueryajaxsettings) { return { abort: function (_, callback: jquerycallback) {
i not interested in first argument of abort function, ignore naming _.
is proper way in typescript? couldn't find in guide. suspect isn't proper way, because can name 1 argument _.
typescript raises following error:
error ts7006: parameter '_' implicitly has 'any' type.
i type _:any
seems bit overkill argument don't use.
there no way skip unwanted parameters in javascript or typescript.
Comments
Post a Comment