Search code examples
visual-studio-codedirectorysubdirectory

VScode fails to make subolder


I am working in a beginner MERN stack project

I am using VS code.

when I make folder(M) and then a sub-folder(a) it's okay
then I try to subfolder inside folder(M) as sub-folder(b)
but it's make like folder(M) -> sub-folder(a) -> sub-folder(b)
my requirement

enter image description here

but in actual VS code

enter image description here


Solution

  • VsCode inlines the tree structure when folders are empty. You have make sure you are really selecting the parent folder when creating a second child folder. If you have selected child folder when creating new folder then you'll end up creating a grand child folder.

    I'll recommend you to checkout this answer to disable compact folders: Turn off visual studio code inline parent/child folder display

    vscode making a subfolder