question

James-9902 avatar image
0 Votes"
James-9902 asked James-9902 answered

SharePoint Online - Modern Site Document Library Display on site

We have created a modern communication site and the goal is to list all document libraries within that site on the homepage in alphabetical order, dynamically i.e so that when a new library is created it is shown.

I have seen the following article: https://sharepoint.stackexchange.com/questions/292959/how-to-sort-by-name-with-the-highlighted-content-web-part however the RefinableString isn't populating after a full crawl.

122757-issue.png

We would prefer not to nest all document libraries within another and was therefore wondering if anyone has any suggestions to achieve the required goal?


office-sharepoint-online
issue.png (16.6 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

CaseyYangMSFT-4714 avatar image
0 Votes"
CaseyYangMSFT-4714 answered

Hi @James-9902,

Per my test, you could use PnP-Search Results web part as a workaround.

Add a new web part > select PnP-Search Results web part > SharePoint Search > Query template {searchTerms}(contentclass:STS_List_DocumentLibrary path:your site url) then you could select RefinableString in Sort order.

123007-1.png


If an Answer is helpful, please click "Accept Answer" and upvote it.

Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.



1.png (18.5 KiB)
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

James-9902 avatar image
0 Votes"
James-9902 answered

@CaseyYangMSFT-4714 are you able to confirm what you set the refinablestring to as it's still not sorting alphabetically for me

5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.