Including Clientlibs for AMP pages in HTL AEM | Community
Skip to main content
Level 2
Nov 20, 2019 1:59 PM UTC
Solved

Including Clientlibs for AMP pages in HTL AEM

Hi All,

We have AMP pages which includes clientlib as like in non-amp page.  We are using data-sly-call to include the css of the clientlibs.  But it's generating the css file as a link in the html at the run time.  So the page is getting failed in the AMP page test.  Is there any other way to include our clientlibs instead of link in HTL.

<sly data-sly-call="${clientLib.css @ categories='myclientlib.category'}"></sly>

is generating below link for the css,

<link rel="stylesheet" href="path/to/css/file.css" type="text/css">

But I need to include/embed the css in html itself.  Is there any way to do that in HTL or using sling?

Thanks,

Velu

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
velmuruganv38Accepted solution
Level 2
Nov 22, 2019 7:34 AM UTC

Hi Jörg Hoh

Sure I will raise issue there.

As of now I have customized cq:includeClientLib tag and included in jsp file. Then I have included the jsp to HTL.

Thanks,

Velu

3 replies

velmuruganv38AuthorAccepted solution
Level 2
Nov 22, 2019 7:34 AM UTC

Hi Jörg Hoh

Sure I will raise issue there.

As of now I have customized cq:includeClientLib tag and included in jsp file. Then I have included the jsp to HTL.

Thanks,

Velu

Translate
Level 2
Jan 27, 2021 9:58 AM UTC

Hi @velmuruganv38, have you raised that issue ? was it resolved ?

Translate
joerghoh
Employee
Nov 20, 2019 6:08 PM UTC

I don't think that the clientlib statements can include the clientlins inline into the (HTML-) page.

But I could imagine that this could be a good addon to ACS AEM Commons. ... maybe you want to post your request there [1] and ask if someone would work on it. You should also open a Adobe support ticket for this (new) feature.

Jörg

[1] Issues · Adobe-Consulting-Services/acs-aem-commons · GitHub

Translate