Stubble v1.0.0-alpha18 Release Notes
Release Date: 2018-07-01 // almost 6 years ago-
Compilation
๐ฆ So we now have a compilation renderer which will allow you to compile your mustache templates to strongly typed functions. This currently doesn't work with the Lambda portion of the spec however has massive speed improvements over standard rendering for templates that don't change too often. This is exposed as an extension package and can be included my going to nuget and looking for
Stubble.Compilation
. For more details on this feature please checkout the readme or look at the docs here.๐ง Configuration Rework
๐ Configuring a renderer has now changed and there is a specific settings builder class which is configured in a
Configure
method on the renderer builder itself. We recommend that all extensions adding extension methods for settings add them toIRendererSettingsBuilder
since they will be easily discoverable by users. For more details on this please see the extension docs here.Migration from the old method to the new method would look something like this
var loader = // Setup custom template loader herevar builder = new StubbleBuilder() .SetTemplateLoader(loader) .SetPartialTemplateLoader(loader) .Build();// Becomesvar builder = new StubbleBuilder() .Configure(settings =\>settings.SetTemplateLoader(loader) .SetPartialTemplateLoader(loader); ) .Build();
Strong Naming
๐ฆ I've removed the strong naming from the core Stubble.Core package due to it requiring people to add binding redirects which can cause all kinds of problems. If you require strong naming we suggest you use strongnamer to resolve anything requiring strong naming to be present.