在线时间:8:00-16:00
迪恩网络APP
随时随地掌握行业动态
扫描二维码
关注迪恩网络微信公众号
开源软件名称(OpenSource Name):KyleGobel/MarkdownSharp-GithubCodeBlocks开源软件地址(OpenSource Url):https://github.com/KyleGobel/MarkdownSharp-GithubCodeBlocks开源编程语言(OpenSource Language):C# 100.0%开源软件介绍(OpenSource Introduction):MarkdownSharp - With Github style code blocksThe original MarkdownSharp can be found on google code here https://code.google.com/p/markdownsharp/ This is basically a fork of that, that has been slightly modified to support github style code blocks. If you're unfamiliar with MarkdownSharp, it's a markdown parser, which was ported from the original perl markdown parser. I believe it is what StackOverflow uses. My light modifications allow this
Which will be transformed to the following html <pre><code class='language-cs'>
public void Main()
{
Console.WriteLine("Github Style Code blocks");
}
</code></pre> Then you can use a library like HighlightJS to sytnax highlight that code block, and since we added the class Whatever is after the 3 ticks will be put in the class name so
would transform to <pre><code class='language-mylanguage'> If anyone wants to add any of the other Github flavored stuff, feel free to pull request. Or, fix my mediocre implementation of the the Github Flavored Codeblocks |
2023-10-27
2022-08-15
2022-08-17
2022-09-23
2022-08-13
请发表评论