Skip to content

Commit

Permalink
Change MarkdigExtensions configuration property to be a comma delimit…
Browse files Browse the repository at this point in the history
…ed string instead of + delimited as Markdig requires for its `Configure()` method.
  • Loading branch information
RickStrahl committed Sep 5, 2017
1 parent 4d4b891 commit a19ea88
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,12 +80,12 @@ public string MarkdigExtensions
get { return _markdigExtensions; }
set
{
if (value == _markdigExtensions) return;
if (value == _markdigExtensions) return;
_markdigExtensions = value;
OnPropertyChanged();
}
}
private string _markdigExtensions = "emphasisextras+pipetables+gridtables+footers+footnotes+citations+attributes";
private string _markdigExtensions = "emphasisextras,pipetables,gridtables,footers,footnotes,citations,attributes";

#endregion

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -122,15 +122,13 @@ protected virtual MarkdownPipelineBuilder CreatePipelineBuilder()
{
if (!string.IsNullOrWhiteSpace(options.MarkdigExtensions))
{
builder = builder.Configure(options.MarkdigExtensions);
builder = builder.Configure(options.MarkdigExtensions.Replace(",","+"));
}
}
catch(ArgumentException ex)
{
// One or more of the extension options is invalid.
// Processing of the extensions stopped at this point.
// Log an error.
mmApp.Log(ex);
mmApp.Log("Failed to load Markdig extensions: " + options.MarkdigExtensions + "\r\n" + ex.Message,ex);
}

return builder;
Expand Down

0 comments on commit a19ea88

Please sign in to comment.