Spring Boot add HTML and JavaScript

后端 未结 7 839
天命终不由人
天命终不由人 2020-12-24 08:50

I\'m trying to run Spring boot app with some HTML5 and JavaScript and I have a problem.

I have project structure like this:

My Spring MVC Controller

7条回答
  •  爱一瞬间的悲伤
    2020-12-24 09:39

    You need to put your static js files into static folder. See more here: https://spring.io/blog/2013/12/19/serving-static-web-content-with-spring-boot

提交回复
热议问题