Top "Thymeleaf" questions

Thymeleaf is an XML/XHTML/HTML5 template engine (extensible to other formats) that can work both in web and non-web environments.

Error: Attempted to call method "format" on null context object

Spring-boot v1.4.1 Java v1.8 Thymeleaf v2.1.5. The following line of code in my view: <td th:each = "sprint : ${sprints}" …

java spring spring-boot thymeleaf date-formatting
Get spring application environment in thymeleaf

My Spring Boot application runs with 3 configurations: application.properties --> for development environment application-test.properties --> for test …

spring environment spring-boot thymeleaf
org.springframework.expression.spel.SpelEvaluationException - Property or field cannot be found on null

I'm using thymeleaf together with spring and there's an error when parsing the following html segment <tbody> <…

spring thymeleaf spelevaluationexception
Flying saucer, Thymeleaf and Spring

I have a Spring application and need to build support for PDF generation. I'm thinking of using Flying-saucer together with …

spring pdf thymeleaf flying-saucer
Spring boot and Thymeleaf - Hot swap templates and resources once again

I tried all tips and tricks that I found here and in docs, but still no luck. I have Spring …

java spring-mvc spring-boot thymeleaf hotswap
Thymeleaf: How to exclude outer tag when using th:each?

The Thymeleaf 2.1.4 official doc demonstrates the for each usage as below: <tr th:each="prod : ${prods}" th:class="${prodStat.…

java template-engine thymeleaf
How to unit test a secured controller which uses thymeleaf (without getting TemplateProcessingException)?

I am trying to run a unit test in spring-boot using spring security and a simple home (root) controller which …

spring-mvc spring-security spring-boot thymeleaf spring-test-mvc
Put CSRF into Headers in Spring 4.0.3 + Spring Security 3.2.3 + Thymeleaf 2.1.2

I have the following code: <!DOCTYPE html> <html xmlns:th="http://www.thymeleaf.org"> <head&…

spring security csrf thymeleaf
How to access model attribute in jQuery

I need to pass a model attribute from controller to HTML. My application is using HTML5, thymeleaf & springboot. I …

jquery html thymeleaf modelattribute
Thymeleaf/Spring MVC - How do you nest variables/expressions in a Link expression?

For example, my controller method in Spring does this: model.addAttribute("view_name", "foobar") And I'm trying to do this …

spring spring-mvc template-engine thymeleaf