Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Extractor ¶
type Extractor interface {
Extract(creativeWork *schema.CreativeWork, path string) error
}
Extractor updates the schema.CreativeWork structure.
type Git ¶
type Git struct {
// contains filtered or unexported fields
}
Git extracts metadata from the Git repository containing Markdown files.
type Markdown ¶
type Markdown struct {
// contains filtered or unexported fields
}
Markdown is an extractor converting the content of .md files to HTML.
func NewMarkdown ¶
NewMarkdown creates a new Markdown extractor
func (Markdown) Extract ¶
func (markdown Markdown) Extract(creativeWork *schema.CreativeWork, path string) error
Extract converts the Markdown syntax to HTML in a secure way. The generated file is sanitized: all special tags and characters stripped (JavaScript, CSS...) or escaped. A "class" attributes containing language indication for syntax highlighting is added to all code snippets. All references to ".md" files are converted to links pointing to ".jsonld" files.
Click to show internal directories.
Click to hide internal directories.