add ability to manage search results settings

This commit is contained in:
sbwalker
2024-07-19 12:55:59 -04:00
parent 5443629ec5
commit 59bba83b1d
10 changed files with 206 additions and 42 deletions

View File

@ -568,20 +568,24 @@
{
if (!string.IsNullOrEmpty(resource.Url))
{
if (!resource.Reload)
{
// if (!resource.Reload)
// {
var url = (resource.Url.Contains("://")) ? resource.Url : alias.BaseUrl + resource.Url;
if (resource.Reload)
{
url += "?" + Guid.NewGuid().ToString("N");
}
return "<script" +
((!string.IsNullOrEmpty(resource.Integrity)) ? " integrity=\"" + resource.Integrity + "\"" : "") +
((!string.IsNullOrEmpty(resource.CrossOrigin)) ? " crossorigin=\"" + resource.CrossOrigin + "\"" : "") +
((resource.ES6Module) ? " type=\"module\"" : "") +
" src=\"" + url + "\"></script>"; // src at end of element due to enhanced navigation patch algorithm
}
else
{
// use custom element which can execute script on every page transition
return "<page-script src=\"" + resource.Url + "\"></page-script>";
}
// }
// else
// {
// // use custom element which can execute script on every page transition
// return "<page-script src=\"" + resource.Url + "\"></page-script>";
// }
}
else
{