0

I have a Spring Boot Application, which uses angular and thymeleaf. The project is structured so that the html files are stored alongside the angular javascript files. My problem is that the javascript files are not being served (getting 404). I know that spring boot servers js and css files from the static folder how could I configure it to find these files?

Folder Structure

resources
----static
----templates
--------view
         index.html
         app.js
---------account
         accountPage.html
         accountCtrl.js

index.html

How could I load the app.js file from the index.html with this file structure?

Mario Dennis
  • 2,986
  • 13
  • 35
  • 50
  • 1
    See the following answer - http://stackoverflow.com/questions/35632175/how-to-change-the-way-spring-boot-serves-static-files/35632734#35632734. Also you can take a look to the other question - http://stackoverflow.com/questions/35968479/spring-boot-cannot-find-index-html-under-webapp-folder – Anton N Mar 13 '16 at 14:31
  • Thanks this worked – Mario Dennis Mar 13 '16 at 14:41

0 Answers0