MustacheProperties has a content-type but this isn't a list and isn't used in the reactive case.

Spring Boot has support for Thymeleaf (reactive only?) configuration to set the support media types of the views as a list, so it seems like they could be more consistent.

Comment From: wilkinsona

Yes, spring.thymeleaf.reactive.media-types is specific to reactive apps.

To be consistent with Thymeleaf in this area, it looks like we're missing a spring.mustache.servlet.content-type property and a spring.mustache.reactive.media-types property.

Comment From: wilkinsona

There's already a spring.mustache.content-type property but it is Servlet-specific. To make that clear it should move to spring.mustache.servlet.content-type. This will mean that MustacheProperties can no longer extend AbstractTemplateViewResolverProperties. There are other spring.mustache.* properties that also appear to be specific to Servlet apps:

  • spring.mustache.allow-request-override
  • spring.mustache.allow-session-override
  • spring.mustache.cache
  • spring.mustache.expose-request-attributes
  • spring.mustache.expose-session-attributes
  • spring.mustache.expose-spring-macro-helpers

We should double-check each of these as part of separating out the reactive- and servlet-specific properties.

Comment From: wilkinsona

Rearranging the properties to make it clear which are Servlet-specific has been done in https://github.com/spring-projects/spring-boot/issues/30273.