Navigate to declaration if it is in index file

Hello,
is there a way for example when I have such structure:


1. As you can see I have "Header component" -> and in the file I am NOT Default exporting it
2. I have index.ts file where I am importing Header and default exporting it

Then in App.tsx file, when I go to "Header" declaration (F12) it goes to the index.ts file.

So is there a way to go directly to the "Header.tsx" file ?
Also for example if I am in the Header.tsx file, when I hit F12 on the declaration it shows where "Header" is used but again it shows that it is used in the "index.ts" file.
So is there a way to skip that "index.ts" file and to show that it is used for exmple here in the App.tsx file ?

I am asking because it is really awful when I want to go to declaration, but it opens the index file, then I have to put the cursor on the function name in the index file and hit F12 again to go to the actual declaration.

For the usages is even awful, because for examle if I want to find all usages of the Header component I have to right click on the index file and "Find Usages"...

0
1 comment

Please vote for https://youtrack.jetbrains.com/issue/WEB-55182 to be notified on any progress with it

1

Please sign in to leave a comment.