Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var Wikilinks = &wikilinks{}
Functions ¶
func NewParser ¶
func NewParser(opts ...ParserOption) parser.InlineParser
func NewRenderer ¶
func NewRenderer(opts ...RendererOption) renderer.NodeRenderer
Types ¶
type ParserOption ¶
type ParserOption interface { parser.Option SetWikilinksOption(*WikilinksConfig) }
A ParserOption interface sets options for the ParserOption.
func WithAltTextOrder ¶
func WithAltTextOrder(value AltTextOrder) ParserOption
func WithTrimSpaces ¶
func WithTrimSpaces(value bool) ParserOption
type RendererConfig ¶
type RendererConfig struct { html.Config Method RenderingMethod RenderFunc RenderFunc }
func (*RendererConfig) SetOption ¶
func (c *RendererConfig) SetOption(name renderer.OptionName, value interface{})
SetOption implements renderer.SetOptioner.
type RendererOption ¶
type RendererOption interface { renderer.Option SetRendererOption(*RendererConfig) }
A RendererOption interface sets options for the emoji renderer.
func WithRenderFunc ¶
func WithRenderFunc(a RenderFunc) RendererOption
func WithRenderingMethod ¶
func WithRenderingMethod(a RenderingMethod) RendererOption
WithRenderingMethod is a functional option that indicates how links are rendered.
type WikilinksConfig ¶
type WikilinksConfig struct { AltTextOrder AltTextOrder TrimSpaces bool }
ParserConfig is a data structure that holds configuration of Wikilinks extension
func (*WikilinksConfig) SetOption ¶
func (w *WikilinksConfig) SetOption(name parser.OptionName, value interface{})
SetOption implements SetOptioner.
Click to show internal directories.
Click to hide internal directories.