JSDoc Element parameter type shows as unresolved when using getElementsByClassName()
When I use @param {Element} or any similar types like HTMLElement in my JsDocs most methods show in autocomplete and don't show up as unresolved in the code inspector. If I use getElementsByClassName, however, it gets flagged as an unresolved method. Similar methods such as getElementsByTagName or getElementById are fine.
Should I be using a different parameter type, or is this a bug?
请先登录再写评论。
getElementsByClassName is defined as
in /plugins/JavaScriptLanguage/lib/JavaScriptLanguage.jar!/com/intellij/lang/javascript/index/predefined/DHTML.js. So you can try using "@param {HTMLDocument}"
Results in exactly the same behaviour - similar methods are fine, getElementsByClassName() shows as unresolved.
works fine for me:
what JS libraries do you have enabled? Please try invalidating caches - does the problem persist?