Our site is currently implemented in SXA 1.5 and Sitecore 8.2 instance.
We generate the styles through the following code in our Main Layout file:
AssetLinks assetLinks = AssetLinksGenerator.GenerateLinks(new ThemesProvider());
@foreach (string style in assetLinks.Styles)
{
@Html.Raw(style)
}
Thus we have the following generated link for Styles (Style optimization set as Optimized in Page Content in SXA)
<link href="/-/media/themes/mysite/styles/optimized-min.css?t=20190819T075414Z" rel="stylesheet" />
Now there is a requirement from the SEO team to add an attribute to the above CSS tag as:
<link rel="preload" href="/-/media/themes/mysite/styles/optimized-min.css?t=20190819T075414Z" as="style">
How can we achieve this customized tag in SXA?