1

I'm playing with my simple NodeJS project in PhpStorm and suddenly the control-click navigation stopped working. When I click on a required file path, I just get message Cannot find declaration to go to. For example:

var Controller = require('./lib/Controller');

The file is definitely there as the program runs without problems. And if I control-click some global function or object (like "require" itself), the navigation works, the definition of the function/object is opened.

It affects now all my NodeJS/JavaScript projects. Is it possible that I simply disabled some kind of code analysis?

I have recently upgraded from PhpStorm 7 to EAP (to get grunt support) and then to 8.0.1. The problem appeared somewhere during the upgrades. I just can't tell exactly when.

4
  • Have you tried File | Invalidate caches... and Restart yet? Commented Sep 22, 2014 at 12:01
  • Yes I have. I also tried to create a new project from existing files but nothing helped. Commented Sep 22, 2014 at 12:02
  • can you attach a screenshot that shows up the issue? Editor + project view so that your actual directory structure is also shown Commented Sep 22, 2014 at 13:00
  • It won't be necessary because I think I have discovered what the problem was. When I was browsing through the settings I noticed that the NodeJS plugin is disabled and marked as "incompatible" with current PHPStorm version. I reinstalled the plugin and the problem was fixed. Commented Sep 22, 2014 at 13:49

1 Answer 1

1

The problem was that the NodeJS plugin was disabled and in my case marked as "incompatible" with current PhpStorm version. Apparently, NodeJS is necessary for navigation through require statements.

It wasn't possible to update the plugin for some reason, so I simply reinstalled it and the problem was fixed.

Sign up to request clarification or add additional context in comments.

1 Comment

You can accept your own answer. Check this article Answering

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.