Skip to content
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

[JavaScript/Node.js] Support for "Go to definition" of code located in "node_modules" #2550

Closed
drywolf opened this issue Jan 29, 2016 · 11 comments
Labels
bug Issue identified by VS Code Team member as probable bug javascript JavaScript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code) verified Verification succeeded
Milestone

Comments

@drywolf
Copy link

drywolf commented Jan 29, 2016

I am using "npm link ../../lib/my-lib" to symlink a local module that is shared across several apps into the "node_modules" directory of each of the apps. This is nice for developing the shared lib in combination with all the apps.

// a standard npm module, can't navigate to its definition
var shortid = require('shortid');
// some functions from a symlink-ed local module inside node_modules, can't navigate to it either
var ModelMountUtils = require('@ipp/loopback-lib').ModelMountUtils;
var RemoteMethodUtils = require('@ipp/loopback-lib').RemoteMethodUtils;

VS-Code does not allow me to navigate to this shared libraries' code by pressing F12 or "Go to definition". The same applies for all other npm modules inside the node_modules directory.

Is this restricted functionality intentional ? or should it be working and I am running to a JS parsing bug that prevents the "Go to definition" to do its work ?
If the "Go to definition" feature is not supposed to work for all things "node_modules" ... could we integrate an exception for symlink directories inside node_modules ?

Thanks

@jrieken jrieken self-assigned this Jan 29, 2016
@jrieken jrieken added javascript JavaScript support issues bug Issue identified by VS Code Team member as probable bug labels Jan 29, 2016
@jrieken
Copy link
Member

jrieken commented Jan 29, 2016

That's a bug. We will soon ship with a revamped JS language support and such things should be fixed then

@drywolf
Copy link
Author

drywolf commented Jan 31, 2016

Nice, I'm looking forward to the next release 😄

@drywolf drywolf closed this as completed Mar 3, 2016
@girvo
Copy link

girvo commented Aug 17, 2016

Just checking, this still seems to be broken in the latest Insider build. Is that expected behaviour? It's a React Native Javascript project, if that matters :)

@zjaml
Copy link

zjaml commented Sep 9, 2016

Subscribed to this too. The feature could be very useful.

@drywolf drywolf reopened this Sep 9, 2016
@jrieken jrieken assigned waderyan and unassigned jrieken Sep 9, 2016
@jrieken
Copy link
Member

jrieken commented Sep 9, 2016

@waderyan This is an issue with the typescript brain

@waderyan
Copy link

waderyan commented Sep 9, 2016

@jrieken just to make sure I understand, when you say "typescript brain" you mean the TypeScript language service, correct?

@jrieken
Copy link
Member

jrieken commented Sep 9, 2016

yes

@waderyan
Copy link

waderyan commented Sep 9, 2016

This issue was moved to microsoft/TypeScript#10808

@waderyan waderyan closed this as completed Sep 9, 2016
@ramya-rao-a
Copy link
Contributor

Moving to next milestone, as this cannot be verified at the moment

@ramya-rao-a ramya-rao-a added this to the October 2016 milestone Sep 28, 2016
@isidorn isidorn added the upstream Issue identified as 'upstream' component related (exists outside of VS Code) label Sep 30, 2016
@mousetraps mousetraps added the verified Verification succeeded label Oct 27, 2016
@nguyennb9
Copy link

Related to #26633 and I think it still not resolves yet.

@tucq88
Copy link

tucq88 commented Sep 21, 2017

@nguyennb9 Me too. Got the same issue with fresh install of Vscode. E.g I'm using Angular 4 and Bulma. Can go to definition of Angular but but it can't go to others. Kind of strange.

@vscodebot vscodebot bot locked and limited conversation to collaborators Nov 17, 2017
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Issue identified by VS Code Team member as probable bug javascript JavaScript support issues upstream Issue identified as 'upstream' component related (exists outside of VS Code) verified Verification succeeded
Projects
None yet
Development

No branches or pull requests

10 participants