Packages

**The extended, configurable markdown-like syntax parser, that produces an AST.** Supports the full set of `markdown`, plus extensions (custom markup with a bit of elixir code to handle parsing.) The AST produced is understandable by [`XmlBuilder`](https://github.com/joshnuss/xml_builder).

Current section

Files

Jump to
markright lib markright parsers dt.ex
Raw

lib/markright/parsers/dt.ex

defmodule Markright.Parsers.Dt do
@moduledoc ~S"""
Parses the input for the line item.
## Examples
iex> input = " item 1
...> ever
...> ▷ item 2
...> "
iex> Markright.Parsers.Dt.to_ast(input)
%Markright.Continuation{ast: [{:dt, %{}, "item 1"},
{:dd, %{}, " ever"}], tail: "\n ▷ item 2\n "}
iex> input = " item 1
...> *ever*
...> ▷ item 2
...> "
iex> Markright.Parsers.Dt.to_ast(input)
%Markright.Continuation{ast: [{:dt, %{}, "item 1"},
{:dd, %{}, [" ", {:strong, %{}, "ever"}]}],
tail: "\n ▷ item 2\n "}
"""
use Markright.Helpers.Lead
end