I am calling one template using data-sly-use. below is the directory structure i have
Now I want to use the template in componentA.html as below. But not able to call template.
<sly data-sly-use.myTemplate="templates/templatesA.html" data-sly-call=""/>
Idea is during using template, avoid the project name in the path i.e. myprj1
How this can be fix.
It doesn't work because the path to the template isn't quite right You use a linux-style relative directory path to point to your templates. In your case, if you are trying to access:
Then the relative path is:
Try using that instead
I reproduced it on my instance using this fix: