java – WEB-INF folder is not creating in Spring Boot application?

java – WEB-INF folder is not creating in Spring Boot application?

We need to crate WEB-INF folder manually in spring boot application. Follow below steps to create WEB-INF folder

  1. Select main folder as highlighted below.

    enter

  2. Right click and create a folder with name webapp.
  3. Now right click on webapp folder and create WEB-INF folder.
  4. Now similarly create a view folder (or any other name you like) inside WEB-INF folder to keep all the JSPs.
  5. Below should be the folder structure after doing above steps.

    enter

Usually the web files will go into the resources folder with spring boot.
https://spring.io/guides/gs/serving-web-content/

java – WEB-INF folder is not creating in Spring Boot application?

Dumping the jsp files in src/main/webapp folder worked for me, both with or without WEB-INF. I followed the exact project structure mentioned in

  1. mkyong.com
  2. springboottutorial

Leave a Reply

Your email address will not be published. Required fields are marked *