用maven配置springboot+freemarker
2024-10-01 01:13:27
1.创建项目
直接点下一步 原因: 不勾选 Create from archetype,是项目创建的骨架的时候,由于不知道什么原因就卡住了,一直在刷新
2.创建之后完成之后
添加依赖
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>1.3.5.RELEASE</version>
</parent>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter</artifactId>
</dependency>
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-web</artifactId>
</dependency>
<!--- 下面是配置freemarker的依赖 START-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-freemarker</artifactId>
</dependency> <!--- 下面是配置freemarker的依赖 END-->
3.将配置文件配置端口
server.port=8089
spring.freemarker.settings.classic_compatible=true
如果将文件需要重新放置文件夹的路径:spring.freemarker.template-loader-path=classpath:/webapp/templates/
4.项目启动完成,显示.
最新文章
- 支付宝web支付
- Linux_磁盘管理
- overflow:hidden---清除浮动,隐藏溢出
- CSS层叠样式表的层叠是什么意思(转自知乎)
- Java异常(一) Java异常简介及其架构
- JS 保留小数点后面2位小数
- resin的基本操作
- 不使用jquery情况下循环添加绑定事件方法
- vue 自定义指令directive
- Fork别人的代码 原作者更新后如何同步
- vue全局使用axios插件请求ajax
- centos 7.4 u盘安装
- Kettle 连接 Oracle 问题总结
- Jmeter实现接口自动化测试
- Git忽略规则和.gitignore规则不生效的解决办法
- b1.关于em和px的关系
- Spring WebSocket踩坑指南
- 把json的字符串变为json对象
- Pascal-S代码注释
- Struts2框架基础概念总结