Key points here is:
-
add
org.springframework.boot:spring-boot-starter-thymeleafdependency inbuild.gradle -
point templates configuration
spring.thymeleaf.prefix=classpath:/public/to public folder insrc/main/resources/application.properties -
during SPA build copy result
index.htmlassrc/main/resources/public/error/4xx.htmlandsrc/main/resources/public/error/5xx.htmlto handle errors with frontend app -
in vue.js frontend app configure error layout in
frontend/layouts/error.vue
links:
other links to read: