usegold

package
v2.0.0-rc14 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 13, 2024 License: MIT Imports: 18 Imported by: 0

README

The goldmark parser

https://github.com/yuin/goldmark

Notes made in late 2023; likely very out of date

GOOD

  • One active, dedicated, awesome maintainer.
  • lots of extensions, proven framework.
  • goldmark is now the markdown renderer for Hugo, replacing blackfriday
  • It already supports mermaid via an extension.
  • It has (at least) 80 releases! https://github.com/yuin/goldmark/releases
  • (at least) 80% coverage
maybe problems
  • Some PRs being ignored by the maintainer. Sure.
  • It doesn't yet support block level attributes, but maybe it's coming.
  • The parser API doesn't seem to return errors.
  • The rendering aspect of the package is pretty tightly bound to its parsing aspect.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type GParser

type GParser struct {
	// contains filtered or unexported fields
}

GParser is a MyFolder tree visitor that both parses and renders markdown. It uses the goldmark parser/renderer to do both.

func NewGParser

func NewGParser() *GParser

func (*GParser) Error

func (v *GParser) Error() error

func (*GParser) FilteredBlocks

func (v *GParser) FilteredBlocks(
	l loader.Label) (result []*loader.CodeBlock)

FilteredBlocks returns a slice of filtered code blocks from the entire tree.

func (*GParser) RenderedMdFiles

func (v *GParser) RenderedMdFiles() []*parsren.RenderedMdFile

func (*GParser) Reset

func (v *GParser) Reset()

func (*GParser) VisitFile

func (v *GParser) VisitFile(fi *loader.MyFile)

func (*GParser) VisitFolder

func (v *GParser) VisitFolder(fl *loader.MyFolder)

func (*GParser) VisitTopFolder

func (v *GParser) VisitTopFolder(fl *loader.MyTopFolder)

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL