34 Fix wrong new-line behavior

This commit is contained in:
Christoph Herb
2025-02-10 17:07:10 +01:00
parent 96ce1d8c9c
commit 517d9f1695
2 changed files with 10 additions and 11 deletions

View File

@@ -20,13 +20,13 @@ This project is a reimplementation of the original Python-based [grip](https://g
## :zap: Features
* :zap: Written in Go :+1:
* 📄 Render markdown to HTML and view it in your browser
* 📱 Dark and light theme
* 🎨 Syntax highlighting for code
* [x] Todo list like the one on GitHub
* Support for github markdown emojis :+1: :bowtie:
* Support for mermaid diagrams
- :zap: Written in Go :+1:
- 📄 Render markdown to HTML and view it in your browser
- 📱 Dark and light theme
- 🎨 Syntax highlighting for code
- [x] Todo list like the one on GitHub
- Support for github markdown emojis :+1: :bowtie:
- Support for mermaid diagrams
```mermaid
graph TD;
@@ -39,7 +39,6 @@ graph TD;
> [!TIP]
> Support of blockquotes (note, tip, important, warning and caution) [see here](https://github.com/orgs/community/discussions/16925)
## :rocket: Getting started
To install go-grip, simply:
@@ -90,8 +89,8 @@ To terminate the current server simply press `CTRL-C`.
## :bug: Known TODOs / Bugs
* [ ] Tests and refactoring
* [ ] Make it possible to export the generated html
- [ ] Tests and refactoring
- [ ] Make it possible to export the generated html
## :pushpin: Similar tools

View File

@@ -26,7 +26,7 @@ var blockquotes = []string{"Note", "Tip", "Important", "Warning", "Caution"}
func (client *Client) MdToHTML(bytes []byte) []byte {
extensions := parser.NoIntraEmphasis | parser.Tables | parser.FencedCode |
parser.Autolink | parser.Strikethrough | parser.SpaceHeadings | parser.HeadingIDs |
parser.BackslashLineBreak | parser.MathJax | parser.HardLineBreak | parser.OrderedListStart
parser.BackslashLineBreak | parser.MathJax | parser.OrderedListStart
p := parser.NewWithExtensions(extensions)
doc := p.Parse(bytes)