For my web application I am using the Maven Standard Directory Layout. With the exception of the place of my sites (I am talking about template files here, *.ftl, *.xslt, etc.).
Instead under src/main/webapp they are at site/ftl
The reason is I develop my application within Eclipse which has it’s root directory set to the project folder. Therefore all files I define will be accessed from the project root directory.
I thought it would be wrong to give a file path which points into a source folder to code which is not actually compiled.
What’s the standard approach here? I don’t use WAR deployment for Tomcat, but Jetty as integrated web server.
As far as I know from java and scala maven projects, the standard place for template files is src/main/webapp/templates or somewhere inside src/main/resources.
As mentioned in Introduction to the Standard Directory Layout, the src/main/webapp is for web application sources. And those sources are commonly should not be compiled, because they are already ready to be executed by the browser.
Web application sources are different from java sources, for instance, as former are executed by the browser without compilation, and latter should be compiled before execution by java plugin.