1.html路径
/src/main/resources/static/pages/send.html
2.controller请求路径
@Controller
@RequestMapping("/websocket")
public class WebsocketController {
@RequestMapping("/send")
public String send() {
return "send";
}
}
3.application.properties配置
#定义视图解析器的规则
spring.mvc.view.prefix=/pages/
spring.mvc.view.suffix=.html
4.浏览器访问