Documentation
¶
Overview ¶
Package parser extends default Goldmark Markdown parser with additional functionality, necessary for building slide presentations.
Index ¶
- Variables
- func Glue(files ...string) ([]byte, error)
- func HasOnlyOneChildOfKind(n ast.Node, k ast.NodeKind) bool
- func IsQuestion(node ast.Node, reader text.Reader) bool
- func New(withOptions ...Option) (_ parser.Parser, err error)
- func NewNotesBreakParser() parser.BlockParser
- func NewReviewQuestionExtractor(extractor QuestionExtractor) parser.BlockParser
- func NewReviewQuestionParser() parser.BlockParser
- func QuestionListFromContext(ctx parser.Context) []ast.Node
- type NotesBreak
- type Option
- type QuestionExtractor
Constants ¶
This section is empty.
Variables ¶
View Source
var KindNotesBreak = ast.NewNodeKind("NotesBreak")
TODO: deprecate in favor of the package `notesbreak`
Functions ¶
func Glue ¶
Glue builds a single Markdown document out of a set of files. Metadata is taken from the first file only.
func HasOnlyOneChildOfKind ¶
TODO: depcrecate in favor of mdextension/figure/HasOnlyOneChildOfKind
func NewNotesBreakParser ¶
func NewNotesBreakParser() parser.BlockParser
NewNotesBreakParser returns a new BlockParser that parses only thematic breaks composed of asterisks. It is based on parser.NewThematicBreakParser, so it should be placed higher in parser priority to work
func NewReviewQuestionExtractor ¶
func NewReviewQuestionExtractor(extractor QuestionExtractor) parser.BlockParser
func NewReviewQuestionParser ¶
func NewReviewQuestionParser() parser.BlockParser
Types ¶
type NotesBreak ¶
type NotesBreak struct {
*ast.ThematicBreak
}
func (*NotesBreak) Kind ¶
func (n *NotesBreak) Kind() ast.NodeKind
type Option ¶
type Option func(*options) error
func WithListItemParser ¶
func WithListItemParser(p parser.BlockParser) Option
func WithQuestionExtractor ¶
func WithQuestionExtractor(extractor QuestionExtractor) Option
Click to show internal directories.
Click to hide internal directories.