1

I'm having an issue with an existing project in React Next.js, previously it was working fine but now it's unable to recognise the project and files. Hence I cannot search for files, and also cannot find in files.

I have tried File > Invalidate Caches but it's still not able to recognise.

Does anyone know what causes this issue, and how to fix it?

Screenshots attached.

WebStorm Project not recognised:

WebStorm Project not recognised

WebStorm Project files not recognised:

WebStorm Project files not recognised

WebStorm cannot search files:

WebStorm cannot search files

WebStorm cannot find in files:

WebStorm cannot find in files

3
  • 2
    Try to close WebStorm, backup and delete .idea directory in the project root. Commented Oct 1, 2021 at 8:57
  • 2
    Your project config seems to be somehow corrupted -- based on your screenshot WebStorm treats all files as "outside of the project". Delete .idea folder as per comment above and re-open the project (may need to use "Open" and point to the project root folder) -- the IDE will create a new project from existing files. Commented Oct 1, 2021 at 11:27
  • Thank you! Tried and it works, project files are detected again. Commented Oct 1, 2021 at 14:52

2 Answers 2

2

Summary based on @s0xzwasd and @LazyOne suggestion:

Issue:

Project config is somehow corrupted. Files are treated as "outside of the project".

Fix/Solution steps:

  1. Close the project from WebStorm.
  2. Backup and delete .idea directory in the project root.
  3. Re-open project.
  4. IDE will create a new project from existing files / treating the files as included in the project.
Sign up to request clarification or add additional context in comments.

Comments

1

It was a permission issue for me, using MacOS Sequoia 15.

Apparently you need to give permission to WebStorm if your project is under Documents, Desktop or Downloads.

Go to Privacy & Settings > Files & Folders > WebStorm.

Comments

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.