Getting Tiles' put-list-attribute to work with a Thymeleaf template

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Getting Tiles' put-list-attribute to work with a Thymeleaf template

balteo
I am trying to get Apache Tiles' put-list-attribute to work with Thymeleaf.

Here is what I tried:

From Tiles config:

<put-list-attribute name="jsFilesList">
 <add-attribute value="/js/libs/jquery-1.8.1.js"/>
  <add-attribute value="/js/libs/jquery-ui-1.9.0.custom.js"/>
  <add-attribute value="/js/libs/bootstrap.js"/>
</put-list-attribute>

From thymleaf template:

<script th:each="jsFile : ${jsFilesList}" th:src="@{${jsFile}}" type="text/javascript" ></script>

Nothing is rendered... It seems the list is empty from the thymeleaf template point of view...

Can anyone please help?