只需要把錯誤放在resources/templates/error/下面,把文件名按照錯誤碼命名就能自動找到頁面
如:/resources/templates/error/404.html
需要一個視圖解析框架:spring-boot-starter-thymeleaf 當然也可以是其他框架
--------------------------------springboot 錯誤頁面源碼邏輯-----------------------------
只需要把錯誤放在resources/templates/error/下面,把文件名按照錯誤碼命名就能自動找到頁面
如:/resources/templates/error/404.html
需要一個視圖解析框架:spring-boot-starter-thymeleaf 當然也可以是其他框架
--------------------------------springboot 錯誤頁面源碼邏輯-----------------------------