'VS Code Explorer is not showing any project directory or files

I have this one project for which VS Code is not showing any files or directories in the Explorer tree

enter image description here

The actual project files and directories at the root are these:

enter image description here

VS Code is working fine for other projects.

How can I fix this?



Solution 1:[1]

Another solution: Go to Settings and check "Files: Exclude" in both "User Settings" and "Workspace Settings". Delete the files/folders needed to appear.

Solution 2:[2]

I had that same problem today (Version: 1.61.0) and fixed it by:

  1. Opening ("Open...") another project on which folders WERE shown.
  2. Opening the original project right after by selecting ("Open..."), but NOT "Open Recent".

Solution 3:[3]

The easiest way it worked for me was to drag the folders from Windows Explorer into VS Code. That restored the entire directory tree for me.

Solution 4:[4]

I was facing the same problem. I reinstalled the vscode and it worked for me.

Solution 5:[5]

This happened to me a while ago and it took me over a month to realize what was happening. In my case, for some reason I added the glob pattern "**/*" for the property Files: Exclude. Basically, I told vscode to exlude all the files in the project, just remove the pattern and you should be fineenter image description here. I hope someone finds this useful.

Solution 6:[6]

create a folder using terminal with command "mkdir folder-name" then go to "file" in menu and then to "open folder" then select the folder u used while creating mkdir. This woked for me.

Solution 7:[7]

Restarting VS Code was enough for me to get it working.

Solution 8:[8]

go to the directory you want then press right click and press open with then select vs code

Sources

This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.

Source: Stack Overflow

Solution Source
Solution 1 Steven Choi
Solution 2 Dharman
Solution 3 Sachin D
Solution 4 Prasanga Thapaliya
Solution 5 ICF
Solution 6 Sindhu Priya V
Solution 7 joalcego
Solution 8 Deeraj N