title: Spring-boot application not finding index.html
body: <p>I am wiring a AngularJS and spring-boot application together by hand for the first time. The issues I am running into is my @RestController is not returning the index page:</p>
  
  <pre><code>@RestController
  public class IndexController {
  
      @RequestMapping("/")
      public String index(){
          System.out.println("Looking in the index controller.........");
          return "index";
      }
  
  }
  </code></pre>
  
  <p>Directory:</p>
  
  <p><a href="https://i.stack.imgur.com/sR7VG.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/sR7VG.png" alt="enter image description here"></a></p>
  
  <p>It keeps rendering the default 404 error page:</p>
  
  <p><a href="https://i.stack.imgur.com/1s49m.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/1s49m.png" alt="enter image description here"></a></p>
  
  <p>----------------UPDATE 1------------------</p>
  
  <p>I have added a configuration file: </p>
  
  <pre><code>@Configuration
  public class IndexPageConfiguration {
  
      @Bean
      public InternalResourceViewResolver viewResolver(){
  
          InternalResourceViewResolver resolver = new InternalResourceViewResolver();
          resolver.setPrefix("/app/");
          resolver.setSuffix(".html");
          return resolver;
  
      }
  
  }
  </code></pre>
  
  <p>RestController</p>
  
  <pre><code>@RestController
  public class IndexController {
  
      @RequestMapping("/")
      public String index(){
          System.out.println("Looking in the index controller.........");
          return "index";
      }
  
  }
  </code></pre>
  
  <p>main class:</p>
  
  <pre><code>@SpringBootApplication(scanBasePackages = { "com.serviceImpl","com.service","com.config" },exclude = { ErrorMvcAutoConfiguration.class })
  public class SpringCrudApplication {
  
      public static void main(String[] args) {
  
          SpringApplication.run(SpringCrudApplication.class, args);
      }
  }
  </code></pre>
  
  <p>The above main class is still returning the default 404 error page.</p>