Forum Discussion

IngeborgHawighorst's avatar
Nov 11, 2020
Solved

Modern PnP search result web part - results layout template

Hello,

 

are there any resources for the PnP Search Results web part results layout that a non-developer can understand?  https://techcommunity.microsoft.com/t5/microsoft-search-blog/creating-custom-search-results-pages-in-sharepoint-online/ba-p/1141515

 

I'd like to know how to re-create the results look and feel from the standard SharePoint results page, specifically, the path to the library and folder with a link. How is that done? I cannot see anything close to this in the Debug view.

 

Any pointers on how to decipher the results layout syntax? I can see HTML elements, and I recognize what some of the nested things do, like this one gets the icon of a file:

 

 

<pnp-fabric-icon data-file-extension='{{IconExt}}' data-image-url='{{SiteLogo}}'></pnp-fabric-icon>

 

 

 

and this one gets the date in long date format

 

 

<span>{{getDate Created "LL"}}</span>

 

 

 

But what other options are there for "getDate"? Where is this language documented? What is it called?

 

Any insights welcome.

 

 

 

2 Replies

Resources