Repository navigation
Description
Recently, support for filtering in Explorer by typing parts of a file or folder name was added (#66497). There are two modes:
The default mode simply highlights all matches in currently expanded folders and scrolls to the first found match. Works perfectly, nicely engineered.
By activating the "Filter on Type" mode, the tree gets pruned to only those elements that match the filter. However, this pruning currently removes all folders which had not been expanded at least once before-hand, no matter if they contain a match or not.
In my opinion, the behavior of the Filter on Type mode is counterintuitive as the results shouldn't depend on how the developer has interacted with the tree in advance. At least then there should be some indication on which folders were not considered in the search. In my case, I commonly want to filter on specific file types, and since there is no "Expand All" feature in the Explorer, the current work-around would be to manually expand all folders upfront and then use the new filter feature so that I can be sure that no entries are missing.
I'm assuming this is related to the fact that folder nodes are lazily resolved since they might be remote resources. On the other hand, the normal search functionality seems to have no problem with these scenarios, probably because the expectation is that it's OK to wait a bit until you get the results, whereas here you more or less want it immediately. Maybe a hybrid would be a good solution: do the quick filtering as it is and display that immediately, and in the background start a regular filename search backed by (still experimental) search provider API. Then merge these when the results come in.
Activity
isidorn commentedon Jan 23, 2019
Thanks for the feature request. In the future no need for such a long explanation - being concise is awesome.
This would be an configuration (or a toggle in the filter). And I would do it only for the explorer, since some trees could not even handle resolving everything (like the debug trees - too many requests to the adapter).
fyi João Moreno (@joaomoreno)
[-]Allow to search all folders while filtering in Explorer without expanding all folders before-hand[/-][+]Explorer: resolve all folders before filtering[/+]eamodio commentedon Jan 25, 2019
Isidor Nikolic (@isidorn) even in the Explorer sidebar it may be very problematic to attempt to search all folders -- because it would be highly dependent on what any
FileSystemProviders are doing behind the scenes.Don't get me wrong -- I would like to see this feature too, but maybe it has to be limited to non-FileSystemProviders -- or a FileSystemProvider would need to express if it can be supported and/or limit the depth?
joaomoreno commentedon Jan 28, 2019
Additionally, this feature should be the offspring of a marriage between Explorer and Search, since the latter can provide with file names much much faster than we could ever do in the Explorer model.
Blum commentedon Feb 14, 2019
I would use the "Quick Open" functionality to achieve this result.
I mean something like:
I also like the explorer with Filter keyboard navigation, but since it gets only the currently visible folders, it is not very useful to me.
sandipchitale commentedon Mar 22, 2019
This extension may be helpful: https://marketplace.visualstudio.com/items?itemName=sandipchitale.revealfolder
Gruntfuggly commentedon Jun 25, 2019
I hadn't quite realised how fundamentally broken this is. I was pulling my hair trying to work out why I couldn't locate a file that I added yesterday. Needing to expand the containing folder first means I might as well not have bothered.
Could there at least be some indication that a folder contains unresolved nodes?
At the moment there is just the note in the January release note - there are probably lots of users who won't find this and it leaves a pretty bad impression.
quolpr commentedon Apr 24, 2020
Any plans on this feature? I cry when I can't find needed file/directory because it is not expanded 😄️
majkinetor commentedon Jun 3, 2020
The filtering is basically unusable because of this. Alternative is CTRL+P anywayz.
kenbanks-peng commentedon Sep 18, 2020
I suggest a 'recursively expand all' is not necessary to fulfill the practical use case. Would just like to have 'expand all my folders of interest'.
I don't mind going through once and recursively opening up all my folders of interest manually. I will not be opening 20,000 folders/files. Convert the 'Collapse Folders' into a toggle between 'Collapse All Folders' / 'Re-open Folders that I previously opened' and the problem is solved, without big performance concerns of 'recursively expand all'.
Deadarius commentedon Jan 15, 2021
Qould be awesome to have this. CMD+P is not a viable alternative for a following usecase: I want to quickly browse through all files containing a specific substring in their names.
44 remaining items
hakan-akgul commentedon Mar 1, 2024
Yes you are right. But it is easy to right click and hide. Also you can unhide directly when you need the file. I will update the comment. Thank you!
hakan-akgul commentedon Apr 2, 2024
I return with a different paradigm.
For a while I'm using rust baseed terminal app broot.
Fast, preview support, fuzzy search. Also it filter lines in preview mode...
Highly recommended. Give a chance.
No need to open side panel for explore files.
ivanglushko commentedon Apr 2, 2024
Thanks for letting us know (will try it out) I tend to use Zed (Rust based) in recent times. It's still in early days but already so good.
ericchase commentedon May 28, 2024
still waiting for expand all folders feature 5 years later
edit:
took me all night, but finally figured out how to build this disaster and then apply the expand
video: https://ericchase.github.io/web--serve/videos/2024-05-28_08.24.36.mp4
pretty simple changes
edit 2:
i realized that expanding 3 layers isn't very impressive, and there's already a semi feature to expand nodes that were previously expanded by the user. so here's a video using it on vscode's code base. notice that expanding such a massive code base is exponentially slower (obvious from the lazy reasoning of what one of the, I presume, devs has stated before on this topic), due to having to load all those files/folders (not sure why vscode works this way when other file explorers can recurse directory listings instantly)
video: https://ericchase.github.io/web--serve/videos/2024-05-28_08.30.54.mp4
starball5 commentedon Oct 4, 2024
Did this get addressed recently? I'm on 1.94 and find widget searches into collapsed folders.
Delapouite commentedon Oct 4, 2024
starball (@starball5) I think you're referring to this announcement in the article https://code.visualstudio.com/updates/v1_94#_find-in-explorer
richbaines commentedon Oct 4, 2024
I've just tested on 1.94 and it looks like this is resolved! Thanks for the heads up starball (@starball5)
gjsjohnmurray commentedon Oct 4, 2024
Unfortunately for people using extensions that rely on the FileSystemProvider API the 1.94 changes are likely to have broken Explorer Find entirely:
#230483
Gosstik commentedon Oct 11, 2024
I work in a VERY large repository and searching recursively through all files takes too much time since version 1.94. Previously, I opened only the folders I needed and searched through them - it was very convenient and the search was carried out instantly. Is it possible to return the previous find logic in explorer in the settings?
rzasukhin commentedon Oct 11, 2024
Just implement it as in xCode. PLease. It cannot be hard.
You should filter-out EMPTY folders without files after filtering.
dimateos commentedon Oct 16, 2024
Yeah an option to keep the previous behavior would be much appreciated!
We also lost the option to NOT filter files and simply highlight them?

IMO resolving all folders should be done only when the user is actually filtering...
Or probably better: add another toggle inside the search input box for resolving all folders!
benibenj commentedon Dec 11, 2024
With the next update you should be able to find files/folders across your entire workspace, including in unresolved folders.