Skip to content

Releases: RickStrahl/Westwind.AspNetCore.Markdown

3.2.2

19 Dec 00:37
Compare
Choose a tag to compare
  • Add Support for Title Detection with === underlines
    Added support for title detection when using a double underscore titles within the first 10 lines of text. Title detection uses Yaml title header first, # headers next, and double underscore === headers last.

3.2

19 Dec 00:37
Compare
Choose a tag to compare
3.2
  • Add support for replacing Markdown Engine
    Added support for an IMarkdownParserFactory to create a custom IMarkdownParserFactory and IMarkdownParser implementation.
    The factory can be applied in the configuration via config.MarkdownParserFactory in Startup.ConfigureServices() of the application.

  • Add support for loading Markdown from a URL
    The Markdown static class and TagHelper now have support for loading Markdown from a URL. Markdown.ParseFromUrl() along with async and HtmlStringVersions as well as a url= attribute on the TagHelper allow for loading Markdown from a URL.

  • Fix: Trailing Slash Handling for Markdown Extensionless Urls
    Fixed issue where a trailing slash would not render Markdown document if a matching .md file is found.
    Note: while pages with backslashes now render, the resulting page may not render properly due to an invalid base path. This is not related to the component but to HTML pathing - the same is true for MVC views for example with releative paths. I highly recommend you don't use a trailinig slash for Markdown Urls to preserve the proper basepath in your document or you ensure ~/ paths in your document.

  • Markdown TagHelper Filename Property
    You can now include Markdown content from the site's file system using the <markdown> TagHelper file the filename attribute. This makes it easy to break out large text blocks and edit and maintain them easily in your favorite Markdown editor vs. editing inline the HTML content. Note that related resources are host page relative, not relative to the Markdown page so plan accordingly for links and image refs.

  • Markdown.ParseFromFile(), ParseFromFileAsync() and .ParseHtmlStringFromFile()
    Like the TagHelper functions above these static methods allow you to load Markdown from a file within the Web site using virtual path syntax (~/MarkdownFiles/MarkdownPartial.md). Note that related resources are host page relative rather than markdown page relative.