Modern Library Search

Copper Contributor

I have a client that is requesting the search results from library level only return folder content type.  I have MS support saying this is not possible.  Does anyone know of a way to filter the search results from a modern library to  only show folders and not the content in the folders?

2 Replies
Are you talking about search in modern document libraries? If so, what support has told you is correct so your options here can be:
(1) Rely on the filters panel in the document library
(2) Develop a custom search solution that can be called from your document library...for instance, a SPFx Extension that opens a side panel or a popup where you can search by folder content type
There is an open source solution available at: https://github.com/estruyf/react-handlebars-search. Note that this will not replace the existing search boxes but is something you could add to a page and point your users to it. This web part more or less emulates what we had available in classic.