My controller returns just a string with the name of template without extension, but it doesn't work till my template has double extension, something like "/WEB-INF/templates/template.html.html".
Actually, that code is taken from different --and, you are right, incompatible-- fragments of code from the tutorial documents. Put together, those fragments don't recognize your view names correctly and force you to the double ".html" extension.
In fact, if you are only using one Spring ViewResolver (i.e. if you are only using Thymeleaf as a view-layer technology) your ViewResolver bean does not need a "viewNames" property at all, because you don't need to make a distinction between which pages will be resolved by thymeleaf and which ones by other template engines --like e.g. JSP--.
If you remove that "viewNames" property, your files will not need the double extension, and you will be able to name your views from at the Spring MVC controller without the ".html" suffix.
Thanks for reply. I have more controllers than this one and they generates json and xml responses. It's comfortable to let spring's ContentNegotiatingViewResolver with favorPathExtension=true controll which view is used. How can I configure thymeleaf to render only *.html requests?