README.md

# mork_to_lustre

[![Package Version](https://img.shields.io/hexpm/v/mork_to_lustre)](https://hex.pm/packages/mork_to_lustre)
[![Hex Docs](https://img.shields.io/badge/hex-docs-ffaff3)](https://hexdocs.pm/mork_to_lustre/)

Adds a `mork_to_lustre.to_lustre` function which takes a mork Document as
argument and outputs a lustre element tree.


```sh
gleam add mork mork_to_lustre@1
```
```gleam
import mork
import mork/to_lustre

pub fn main() -> Nil {
  let markdown = "# Hello, Joe!\n"
  let e = markdown |> mork.parse |> to_lustre.to_lustre
  let e = e |> element.fragment |> element.to_string

  assert e == "<h1>Hello, Joe!</h1>"
}
```

Further documentation can be found at <https://hexdocs.pm/mork_to_lustre>.

## Development

```sh
gleam run   # Run the project
gleam test  # Run the tests
```