Springboot加载thymeleaf模板引擎

第一步:pom文件引入thymeleaf模板引擎依赖。 第二步:在resources目录中的templates目录中新建html页面。 第三步:通过编写的Controller类来执行html页面的跳转,注意:在templates目录下的所有页面,只能通过controller来跳转。  第四步:浏览器中访问获得页面。 第五步:动态传递数据。  
相关文章
相关标签/搜索