eclipse - JSDoc - how to check types for JavaScript -


i applying jsdoc annotations:

/**  * @param {number} millis  * @param {function} callback  * */ function sleep(millis, callback) {     settimeout(function() {         callback();     }, millis); } 

then tool tell there error line below?

sleep('aaa', 'sdsdsd'); 

is jshint aware of jsdoc type annotations? how enable such support in eclipse?

disclaimer, i'm author of tern.java.

i suggest you install tern.java 1.0.0-snapshot. provides capability validate javascript files using jsdoc annotations. here screenshot sample of issue :

enter image description here

if need improvement jsdoc validation, please create issues here


Comments

Popular posts from this blog

c# - How to get the current UAC mode -

postgresql - Lazarus + Postgres: incomplete startup packet -

javascript - Ajax jqXHR.status==0 fix error -