Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lpil/jot
A parser for Djot, a markdown-like language.
https://github.com/lpil/jot
Last synced: 21 days ago
JSON representation
A parser for Djot, a markdown-like language.
- Host: GitHub
- URL: https://github.com/lpil/jot
- Owner: lpil
- Created: 2023-11-15T19:46:10.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-04-30T12:38:08.000Z (8 months ago)
- Last Synced: 2024-05-01T23:05:04.974Z (7 months ago)
- Language: Gleam
- Homepage:
- Size: 47.9 KB
- Stars: 18
- Watchers: 3
- Forks: 6
- Open Issues: 1
-
Metadata Files:
- Readme: README.md
- Changelog: CHANGELOG.md
Awesome Lists containing this project
- awesome-gleam - jot - [📚](https://hexdocs.pm/jot/) - A parser for Djot, a markdown-like language (Packages / Formats)
README
# jot
A parser for [Djot][djot], a markdown-like language.
[djot]: https://djot.net/
[![Package Version](https://img.shields.io/hexpm/v/jot)](https://hex.pm/packages/jot)
[![Hex Docs](https://img.shields.io/badge/hex-docs-ffaff3)](https://hexdocs.pm/jot/)```sh
gleam add jot
```
```gleam
import jotconst document = "
# Hello, Joe!This is a [Djot][djot] document.
[djot]: https://www.djot.net/
"pub fn main() {
// Turn the document into HTML
let html = jot.to_html(document)// Alternatively, parse the document to an AST
let ast = jot.parse(document)
}
```Further documentation can be found at .
## Status
This project is a work in progress. So far it supports:
- [x] Headings
- [x] Paragraphs
- [x] Links (inline and reference)
- [x] Images
- [x] Code blocks
- [x] Inline code
- [x] Emphasis and strong
- [x] Block attributes
- [x] Manual line breaks
- [x] Thematic breaks