For the frontend we are going to be using Thymeleaf. When you add Thymeleaf to your project using the spring-boot-thymeleaf-starter you will get support for both Thymeleaf V2.x and Thymeleaf V3.x. By default the V2.x support is activated by the starter but if you want to use V3.x then you can easily add some properties to your pom.xml file. I want to use V3…
Once you have updated the pom.xml file it it time to create the applications first page. This is done in the resources/templates folder and should be called home.html to match the string returned by the controller we created.
The html file is a standard html file but I have added a xml namespace declaration to the html tag to indicate that I’m using thymeleaf. This helps the IntelliJ html editor to provide extra hints and autocompletion for thymeleaf tags. I have not added any thymeleaf tags just yet but I will in the future. I would also suggest that you update your IDEs code template to add the tag there so that you don’t have to do it ever time in your projects.
If you were to run the application right now it would look fairly boring…
In the next part I will spruce it up a little by adding a simple Bootstrap layout..