11 questions
0
votes
0
answers
28
views
Caching rendered templates in Spring Boot
I'm using the JTE template engine in a Spring Boot application like:
@GetMapping("/")
public String home(Model model) {
List<Product> products = productRepo.findAll();
model....
0
votes
1
answer
54
views
Template calls in <script> blocks are not allowed
I'm using the jte template engine within a Spring-Boot project and need to include a template into a <script> tag:
<script type="application/ld+json">
@template.pages.json-ld(...
0
votes
1
answer
38
views
Static resource not being hotloaded
I am using tailwindcss version 4 via npx to watch my source files "../jte/**" and rebuild the static resource main.css. However when it is rebuilt, it will occasionally take a long time to ...
0
votes
1
answer
101
views
JTE throw java.lang.ClassNotFoundException with SpringBoot 3
I'm trying use JTE in Spring Boot 3.2. This configuration worked in test, but failed in Docker container with app. I need non-HTML templates for file generating, so I'm not using jte-spring-boot-...
0
votes
0
answers
62
views
Html Controls events in Java template engine JTE + Springboot
@template.layout.index(
content = @`
<script>
function toggleManualFields() {
// Get the checkbox element
const checkbox = document.getElementById('isManual');...
3
votes
2
answers
759
views
How to use TailwindCSS v4 with spring boot and Java template Engine
I am using Spring boot application with Java template engine and when I did the setup for v3, a tailwind.config.js file was present to check for the JTE files as below:
/** @type {import('tailwindcss')...
0
votes
1
answer
271
views
NoClassDefFound when trying to render a jte template
I have a small kotlin project using Javalin and JTE as a renderer. The project is managed with maven and below is the pom.xml.
<?xml version="1.0" encoding="UTF-8"?>
<...
1
vote
0
answers
119
views
Java template engine with spring boot application not running in Intellj
I am using the Spring authorization server with custom branding and a custom login page, with the below dependency and configuration and java template engine.
plugins {
java
id("org....
2
votes
1
answer
521
views
Best way to automatically add CSRF Token to Spring Boot JTE main template
I like the new template engine JTE and I am trying to learn this.
I know I can manually add the CSRF token as a request attribute and I have done it for my login form like so:
@GetMapping("/login&...
0
votes
2
answers
1k
views
How to apply Tailwind CSS style to a JTE template using Java Spring Boot?
I am experimenting with the new JTE template and even though it works fine to display values through my HTML, I'm struggling to get the Tailwind CSS styles to show up.
I have a Tailwind autogenerated ...
2
votes
2
answers
2k
views
JTE precompile in production is not working for Spring Boot 3.3
I am trying to use JTE template in Spring Boot 3.3 it is working during dev environment. During production deploy pre compilation is working but I am getting runtime error when I visit that route. For ...