I am using spring boot to try and build my own mini website.
I have a controller
package hello;
import org.springframework.web.bind.annotation.RestController;
import org.springframework.web.bind.annotation.RequestMapping;
@RestController
public class HelloController {
@RequestMapping("/greeting")
public String index() {
return "index";
}
}
and a html file resources/templates/index which I am trying to render but I just get the text "index" rendered. How can I return the html file instead of the text?