Error reported by thymeleaf:
An error happened during template parsing (template: “class path resource [templates/hello.html]”)] with root cause……
Each of the following is a single solution! Not a step
1. Clear your compiler cache! And restart
2. Clear the browser cache Ctrl + Shift + Del
3. Check the configuration file (. POM file): whether it contains dependencies. If not, please add it
<dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-thymeleaf</artifactId> </dependency>
4. In application. properties
#Set prefix and suffix spring.thymeleaf.mode=HTML spring.thymeleaf.suffix=.html spring.thymeleaf.prefix=classpath:/templates/
5. Is it a coding problem? The code here refers to the code with errors, syntax, and other problems
Similar Posts:
- Springboot always reports an error when importing JSP dependencies
- [How to Solve] RestController cannot be recognized in spring boot
- [Solved] Swagger Error: Failed to start bean ‘documentationPluginsBootstrapper’
- Springboot startup error start bean ‘eurekaautoserviceregistration’ NullPointerException
- Pom.xml add dependency error [How to Solve]
- [Solved] java.lang.NoSuchMethodError: javax.persistence.spi.PersistenceUni
- ERROR in ch.qos.logback.core.joran.spi.Interpreter@73:41 – no applicable action for [AppenderRef], current ElementPath is [[Configuration][Loggers][Root][AppenderRef]]
- Unregistering JMX-exposed beans on shutdown Solution
- [Solved] Springboot integrate swagger Error: failed to start bean ‘documentationpluginsboot
- [Solved] Whitelabel page error when using Swagger2 in SpringBoot