728x90 thymeleaf1 Thymeleaf 탬플릿 엔진 JSP 단점 > 서블릿 엔진이 JSP 스펙을 구현하여 최종적인 뷰가 나옴 - 랜더링된 결과를 확인하기 힘듬 > Thymeleaf 를 사용하면 Thymeleaf가 독자적으로 (Servlet Container의 개입 없이) View를 완성하여 랜더링된 결과를 확인하기 쉬움 (웹서버를 안띄워도 mockMVC만으로 test가 가능하다.) 예제) controller @Controller public class SampleController { @GetMapping("/hello") public String hello(Model model){ model.addAttribute("name", "sangguk"); //model > attribute return "hello"; //view name } }.. 2022. 2. 28. 이전 1 다음 728x90