title: Eclipse vs. Spring Boot gives JSP error: Fragment "/js/home.js" was not found at expected path /src/main/webapp/js/home.js
body: <p>I have the line</p>
  
  <pre><code>&lt;script type="text/javascript"&gt;
    &lt;%@include file="/js/home.js" %&gt;
  </code></pre>
  
  <p>Which gives the error in title. The JS files are in <code>/src/main/resources/static/js</code>. The error goes away if I create <code>/src/main/webapp/js/home.js</code>. This answer says <code>webapp/</code> is not recommended. <a href="https://stackoverflow.com/a/28727189/148844">https://stackoverflow.com/a/28727189/148844</a>. We are using JARs and we are uploading a WAR to AWS via the web console. Eclipse expects <code>webapp/js/</code> and Spring Boot expects <code>resources/static/js</code>, so which should I use? How do I tell Eclipse how to find the JS file?</p>
  
  <pre><code>$ tree
  ├───src
  │   ├───main
  │   │   ├───java
  │   │   ├───resources
  │   │   │   └───static
  │   │   │       ├───css
  │   │   │       ├───fonts
  │   │   │       ├───img
  │   │   │       └───js
  │   │   └───webapp
  │   │       └───WEB-INF
  │   │           └───jsp
  </code></pre>
  
  <p>We also have</p>
  
  <pre><code>spring.mvc.view.prefix: /WEB-INF/jsp/
  spring.mvc.view.suffix: .jsp
  </code></pre>
  
  <p>Eclipse Version: Photon Release (4.8.0)</p>