Class HandlebarsConfiguration


  • @Configuration
    public class HandlebarsConfiguration
    extends Object
    Configure handlebar template engine.
    • Constructor Detail

      • HandlebarsConfiguration

        public HandlebarsConfiguration()
    • Method Detail

      • mustacheCompiler

        @Bean
        public MustacheCompiler mustacheCompiler​(com.github.jknack.handlebars.Handlebars handlebars,
                                                 MustacheTemplateLoader templateLoader)
        Build mustache compiler. This compiler use an instance of Handlebars under the hood.
        Parameters:
        handlebars - Handlebars instance.
        templateLoader - Template loader.
        Returns:
        Mustache compiler implementation.
      • handlebarsCompiler

        @Bean
        public HandlebarsFactoryBean handlebarsCompiler()
        Build original Handlebars compiler that will be used to compile and render templates.
        Returns:
        Handlebars compiler.