API
Provides tools for working with Gemtext.
Gemtext
Gemtext(text: str, *, with_spartan_support: bool = True)
A Gemtext parser.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
|
str
|
The Gemtext content to parse. |
required |
|
bool
|
Whether to support Spartan protocol prompts. |
True
|
Heading
Line
Link
Link(uri: str, description: str)
PreFormatted
SpartanPrompt
Bases: Link
A Spartan protocol link that prompts for input.
Note
This is a subclass of Link, as it behaves similarly to a
link in Gemtext.
This class will only ever be created if the Gemtext parser is
initialized with with_spartan_support=True.
Otherwise, Spartan prompts will be treated as regular paragraphs.