instanceof not working
I wanted to try to write my first plugin, however I got stuck quite early on. I want to add a simple Annotator at first which should be run when it encounters a JSStringTemplateExpression. I added the jars from plugins\JavaScriptLanguage\lib to my classpath and everything compiles fine. However when I try run a check ```
if (element instanceof JSStringTemplateExpression) {
```
it is false. I debugged the jar location and class name and it seems to be the same, just the check doesn't work.
I also added this to my plugin.xml
```
<extensions defaultExtensionNs="com.intellij">
<annotator language="TypeScript" implementationClass="com.feather.idea.FeatherAnnotator"/>
</extensions>
```
Any ideas what I'm doing wrong?
请先登录再写评论。
This thread answered my probem: https://intellij-support.jetbrains.com/hc/en-us/community/posts/206762465-How-do-I-make-use-of-the-javascript-psi-