You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Your 'Go to Declaration' feature when pressing F12 is awesome!
I'd like to request a 'Go to Implementation' feature as well. When you 'Go to Declaration' as currently implemented you often arrive at the typescript .d.ts file which has the function signature but not the actual implementation. It would be great if there were a different key combination that would go to the implementation or if the 'Go to Declaration feature' would offer a list to choose either the type definition or the implementation.
At the moment what I do to work around this is search for 'class or similar full project searches, but it would be really great to find the implementation immediately.
At the moment what I do to work around this is search for 'class or similar full project searches, but it would be really great to find the implementation immediately.
It might not be of much use in general projects because of TypeScript's type system being structural. e.g. The TypeScript source code has types declared in types.ts with constructors being just functions that return objects that conform to the interface. E.g. see Node creation : https://basarat.gitbooks.io/typescript/content/docs/compiler/parser-functions.html#node-creation in the typescript source 🌹
So there is no mention of implements Foo. I do understand the motiviation for implements Foo. Maybe raise an issue at Microsoft/TypeScript and link back here to see if they are willing to provide a language service endpoint so we don't have to write it 🌹
For finding stuff I generally use find references which is already supported 🌹
I just tried Find References again in various combinations but it never does what this request is asking for which is to show the implementation of the type. It does show all places that the type is used but doesn't show the implementation of that type.
There is a implements keyword in Typescript itself for implementing interfaces, but I'm interested in more than just the implements keyword to know what interfaces are defined. I'd like to also be able to find those functions and classes which conform to the type.
I just tried Find References again in various combinations but it never does what this request is asking for which is to show the implementation of the type
Sorry. I misread the question. But your request on Microsoft/TypeScript is still the right way to go 🌹
Activity
basarat commentedon Dec 21, 2015
It might not be of much use in general projects because of TypeScript's type system being structural. e.g. The TypeScript source code has types declared in
types.tswith constructors being just functions that return objects that conform to the interface. E.g. see Node creation : https://basarat.gitbooks.io/typescript/content/docs/compiler/parser-functions.html#node-creation in the typescript source 🌹So there is no mention of
implements Foo. I do understand the motiviation forimplements Foo. Maybe raise an issue atMicrosoft/TypeScriptand link back here to see if they are willing to provide a language service endpoint so we don't have to write it 🌹For finding stuff I generally use find references which is already supported 🌹
doliver3 commentedon Dec 22, 2015
Ok, I've opened this related request to the Typescript team: microsoft/TypeScript#6209
I just tried Find References again in various combinations but it never does what this request is asking for which is to show the implementation of the type. It does show all places that the type is used but doesn't show the implementation of that type.
There is a implements keyword in Typescript itself for implementing interfaces, but I'm interested in more than just the implements keyword to know what interfaces are defined. I'd like to also be able to find those functions and classes which conform to the type.
basarat commentedon Dec 22, 2015
Sorry. I misread the question. But your request on Microsoft/TypeScript is still the right way to go 🌹