I am trying to use thymeleaf as it is described in all tutorials but somehow my HTML doesn't get loaded.
Here is my project structure:
dependencies {
testCompile group: 'junit', name: 'junit', version: '4.12'
compile("org.springframework.boot:spring-boot-starter-web:2.0.4.RELEASE")
compile group: 'org.thymeleaf', name: 'thymeleaf', version: '2.0.5'
}
It does nothing much but prints out "Hello" message, however, the HTML from resources folder is not used. What am I missing?
The HelloController.java has only 1 method:
@RequestMapping("/hello")
public String hello(Model model, @RequestParam(value="name",
required=false, defaultValue="World") String name) {
model.addAttribute("name", name);
return "hello " + name;
}
And main method is just the usual run.