4

I want to use plain html views in a JHipster project as a landing page. Is there a best practice for a Spring-Boot controller? My goal is to use a non-angular html page for the path "/". The angular-index.html is loaded automatically by spring boot defaults. I do not understand how i can make use this autoconfiguration of spring boot and at the same time have a non-angular view for the path "/".

@RequestMapping("/")
public String hi() {
    return "hi";
}

This is the method to render the "hi.html" view, located in /resources/templates. The view is displayed correctly but i can not address the angular app anymore (ex. /home).

Jeroen Kransen
  • 1,379
  • 3
  • 19
  • 45
Interfaced
  • 124
  • 3
  • 10
  • You may also want to take a look at: https://stackoverflow.com/questions/55705637/how-to-set-base-url-for-angular-application/55761093 It is a similar, if not duplicate, question. – Jeroen Kransen Apr 20 '19 at 05:20

0 Answers0