org v0.1.0 Org.Section
Represents a section of a document with a title and possible contents & subsections.
Example:
iex> source = "* Hello\nWorld\n** What's up?\nNothing much.\n** How's it going?\nAll fine, whow are you?\n"
iex> doc = Org.Parser.parse(source)
iex> section = Org.section(doc, ["Hello"])
iex> section.contents
[%Org.Paragraph{lines: ["World"]}]
iex> length(section.children)
2
iex> for child <- section.children, do: child.title
["What's up?", "How's it going?"]
Link to this section Summary
Functions
Adds content to the last prepended section
Link to this section Types
Link to this type
t()
t() :: %Org.Section{children: [Org.Section.t()], contents: [Org.Content.t()], title: String.t()}
Link to this section Functions
Link to this function
add_nested(parent, level, child)
Link to this function
contents(section)
Link to this function
find_by_path(arg1, path)
Link to this function
prepend_content(section, content)
Adds content to the last prepended section
Link to this function
reverse_recursive(section)
Link to this function
update_content(section, updater)