Options
All
  • Public
  • Public/Protected
  • All
Menu

Callable

  • marked(src: string, callback: function): string
  • marked(src: string, options?: MarkedOptions, callback?: undefined | function): string
  • Compiles markdown to HTML.

    Parameters

    • src: string

      String of markdown source to be compiled

    • callback: function

      Function called when the markdownString has been fully parsed when using async highlighting

        • (error: any | undefined, parseResult: string): void
        • Parameters

          • error: any | undefined
          • parseResult: string

          Returns void

    Returns string

    String of compiled HTML

  • Compiles markdown to HTML.

    Parameters

    • src: string

      String of markdown source to be compiled

    • Optional options: MarkedOptions

      Hash of options

    • Optional callback: undefined | function

      Function called when the markdownString has been fully parsed when using async highlighting

    Returns string

    String of compiled HTML

Index

Modules

Classes

Interfaces

Type aliases

Functions

Type aliases

Token

TokensList

TokensList: Token[] & object

Functions

lexer

  • Parameters

    • src: string

      String of markdown source to be compiled

    • Optional options: MarkedOptions

      Hash of options

    Returns TokensList

parse

  • parse(src: string, callback: function): string
  • parse(src: string, options?: MarkedOptions, callback?: undefined | function): string
  • Compiles markdown to HTML.

    Parameters

    • src: string

      String of markdown source to be compiled

    • callback: function

      Function called when the markdownString has been fully parsed when using async highlighting

        • (error: any | undefined, parseResult: string): void
        • Parameters

          • error: any | undefined
          • parseResult: string

          Returns void

    Returns string

    String of compiled HTML

  • Compiles markdown to HTML.

    Parameters

    • src: string

      String of markdown source to be compiled

    • Optional options: MarkedOptions

      Hash of options

    • Optional callback: undefined | function

      Function called when the markdownString has been fully parsed when using async highlighting

    Returns string

    String of compiled HTML

parser

  • Parameters

    Returns string

setOptions

  • Sets the default options.

    Parameters

    Returns marked

Generated using TypeDoc