Hierarchy

  • Renderer

Constructors

  • Parameters

    • name: string
    • regex: String | RegExp

    Returns Renderer

Properties

#config: Configuration
#name: string
#regex: RegExp[]

Accessors

  • get layoutDirs(): string[]
  • Returns string[]

  • get partialDirs(): string[]
  • Returns string[]

Methods

  • Compute the file extension from the input file name.

    Returns

    Parameters

    • fname: any

    Returns string

  • Compute the pathname which a given input file should have after being rendered.

    For example, an input file example.html.md would have an output file name example.html.

    Returns

    Parameters

    • fname: any

    Returns string

  • Test whether the file name matches a known Renderer.

    Returns

    Parameters

    • fname: any

    Returns boolean

  • Parse any metadata in the document, by default no parsing is done. A Renderer that supports files which contain metadata should implement this function to parse that metadata.

    A function, parseFrontmatter, is available to parse frontmatter block at the top of a file.

    Returns

    Parameters

    Returns RenderingContext

  • Parameters

    • basedir: any
    • fpath: any

    Returns Promise<string>

  • Parameters

    • basedir: any
    • fpath: any

    Returns string

  • Render input data using only synchronous code, producing output data. Some execution contexts can only run synchronous code.

    Parameters

    Returns string

  • Parameters

    • sourcePath: any
    • rendersTo: any

    Returns boolean

  • Parameters

    • renderTo: any
    • fpath: any
    • text: any

    Returns Promise<void>

  • Parameters

    • renderTo: any
    • fpath: any
    • text: any

    Returns void