How to implement custom string redirection?
Answered
I want to redirect an API path to a tree node in custom window, just like below:
```
String path = “/users/{id}”;
let path="/users/{id}";
```
Please sign in to leave a comment.
You mean provide navigation/goto declaration from the code to your custom toolwindow?
Using “Select In..” popup via
com.intellij.ide.SelectInTarget
.Or for “goto declaration”, resolve the reference from the String literal to dummy
com.intellij.psi.impl.FakePsiElement
and usenavigate()
to open tool window.