Skip to content

Commit

Permalink
fix: Fix Portlet preloading URL and Crossorigin - Meeds-io/meeds#2483 (
Browse files Browse the repository at this point in the history
…#234)

Prior to this change, the URL to preload when displaying the page is
different from the loaded fetch call using JS services of the page
layout. In addition, the crossorigin attribute has to be the same as the
fetch call 'credentials' attribute which is with value 'include'.

Resolves Meeds-io/meeds#2483
  • Loading branch information
boubaker authored Oct 11, 2024
1 parent b74dde7 commit f1ca807
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
def portletId = portlets.get(i).getId();
if (portletId != null) {
%>
<link rel="prefetch" as="fetch" type="text/html" href="<%=rcontext.getRequest().getRequestURI()%>?maximizedPortletId<%=portletId%>&showMaxWindow=true&hideSharedLayout=true&maximizedPortletMode=VIEW" crossorigin><%
<link rel="preload" as="fetch" href="<%=rcontext.getRequest().getRequestURI()%>?maximizedPortletId=<%=portletId%>&showMaxWindow=true&hideSharedLayout=true&maximizedPortletMode=VIEW" crossorigin="use-credentials"><%
}
}
}
Expand Down

0 comments on commit f1ca807

Please sign in to comment.