An open API service indexing awesome lists of open source software.

https://github.com/13rac1/goldmark-hashtag

A Hashtag extension for the goldmark markdown parser.
https://github.com/13rac1/goldmark-hashtag

goldmark goldmark-extension hashtags markdown

Last synced: 2 months ago
JSON representation

A Hashtag extension for the goldmark markdown parser.

Awesome Lists containing this project

README

        

# goldmark-hashtag

goldmark-hashtag is an extension for the [goldmark][goldmark] library to handle
`#example` hashtags providing a Hashtag AST type.

[goldmark]: http://github.com/yuin/goldmark

## Demo

This markdown:

```md
# Hello goldmark-hashtag

#example
```

With the default configuration, becomes this HTML:

```html

Hello goldmark-hashtag


#example


```

### Installation

```bash
go get github.com/13rac1/goldmark-hashtag
```

## Usage

```go
markdown := goldmark.New(
goldmark.WithExtensions(
hashtag.Extension,
),
)
var buf bytes.Buffer
if err := markdown.Convert([]byte(source), &buf); err != nil {
panic(err)
}
fmt.Print(buf)
}
```

## License

MIT

## Author

Brad Erickson