Skip to content

Commit 2999f09

Browse files
committed
Rework tip on templates location in the IDE
This commit rework the tip on locating templates when running the app in the IDE. Using classpath* should not change anything as this won't make a difference without a pattern in the path. Closes gh-23068
1 parent 7f84a92 commit 2999f09

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

spring-boot-project/spring-boot-docs/src/main/asciidoc/spring-boot-features.adoc

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2337,11 +2337,10 @@ There are several <<boot-features-jsp-limitations, known limitations>> when usin
23372337

23382338
When you use one of these templating engines with the default configuration, your templates are picked up automatically from `src/main/resources/templates`.
23392339

2340-
TIP: Depending on how you run your application, IntelliJ IDEA orders the classpath differently.
2340+
TIP: Depending on how you run your application, your IDE may order the classpath differently.
23412341
Running your application in the IDE from its main method results in a different ordering than when you run your application by using Maven or Gradle or from its packaged jar.
2342-
This can cause Spring Boot to fail to find the templates on the classpath.
2342+
This can cause Spring Boot to fail to find the expected template.
23432343
If you have this problem, you can reorder the classpath in the IDE to place the module's classes and resources first.
2344-
Alternatively, you can configure the template prefix to search every `templates` directory on the classpath, as follows: `classpath*:/templates/`.
23452344

23462345

23472346

0 commit comments

Comments
 (0)