-
Notifications
You must be signed in to change notification settings - Fork 30.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Go to definition doesn't work #19672
Comments
Can you please provide some example code or an example project that shows this problem so that we can investigate this. |
Clicking CMD+ left click on 'React' for example guide us to index.d.ts. In WebStorm on the other hand we're sent to source code of react.js. |
This is currently as designed. Our JavaScript language support is powered by TypeScript and the way that TypeScript is able to provide rich support for JavaScript libraries is by using I believe that TypeScript is tracking the ability to jump to an JavaScript implementation here: microsoft/TypeScript#6209 |
I'm sufficiently frustrated by this issue to tell you why: "Go to definition" is such a basic feature and you guys won't just figure out a way to get it done. Instead, you're pointing us to a 1.5 year old TypeScript issue that got removed from their road map as soon as the TypeScript implementation was finished. This has got to be one of the issues that keeps many people from using vscode because it makes me think that you don't care about the actual work that I need to do with this tool. IMO, you guys should be on fire for this issue. At the very least, hack together a plugin to cover the most basic scenario (navigating to the import React from 'react'; // [B]
class Thing extends React.Component { // [A]
render() {
return <div>Thing</div>;
}
}
If that's all you can do for now - it's better than nothing. See also: #25197 |
I have to agree, I'm trying to switch to vscode as its much faster than webstorm, but the fact that I can't navigate code removes 90% of the reason I use an editor. I can't even jump to declarations that are in the same file sometimes and there's no explanation given. Version The code for the project I'm working on unfortunately cannot be shared. |
I'm also wondering why this issue was closed. "Go to definition" does not work even when everything is in Typescript. It's quite frankly bizarre. This is one of the basic features every IDE should have. |
i need this feature |
I need this too. For me it doesn't even work within the same file, and as others have said here, it's a very basic, essential feature in an editor. I've been impressed with VS Code, but this is a deal-breaker, and it's also discouraging to see this issue closed, leading me to think the maintainers of the project just don't care what people need. |
I am working a project with no TypeScript, and adding this to settings solves for me:
(it still goes to |
I was initially very happy with vscode, and still somewhat are, but this is definitely the most frustrating issue I've come across. I need this fixed, please |
me too, may be there is a config to define how is go to defined work |
I cannot check the imported modules code for some reason. Go to definition doesn't work or simply jumps to index.d.ts instead.
The text was updated successfully, but these errors were encountered: