@types/marked

  • Version 4.0.1
  • Published
  • 23.3 kB
  • No dependencies
  • MIT license

Install

npm i @types/marked
yarn add @types/marked
pnpm add @types/marked

Overview

TypeScript definitions for Marked

Index

Functions

function marked

marked: typeof marked;
  • Compiles markdown to HTML synchronously.

    Parameter src

    String of markdown source to be compiled

    Parameter options

    Optional hash of options String of compiled HTML

  • Compiles markdown to HTML asynchronously.

    Parameter src

    String of markdown source to be compiled

    Parameter callback

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

  • Compiles markdown to HTML asynchronously.

    Parameter src

    String of markdown source to be compiled

    Parameter options

    Hash of options

    Parameter callback

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

Classes

class Lexer

class Lexer extends marked.Lexer {}

    class Parser

    class Parser extends marked.Parser {}

      class Renderer

      class Renderer<T = never> extends marked.Renderer<T> {}

        class Slugger

        class Slugger extends marked.Slugger {}

          class TextRenderer

          class TextRenderer extends marked.TextRenderer {}

            class Tokenizer

            class Tokenizer<T = never> extends marked.Tokenizer<T> {}

              Namespaces

              namespace marked

              namespace marked {}

                variable defaults

                const defaults: MarkedOptions;

                  function getDefaults

                  getDefaults: () => MarkedOptions;
                  • Gets the original marked default options.

                  function lexer

                  lexer: (src: string, options?: MarkedOptions) => TokensList;
                  • Parameter src

                    String of markdown source to be compiled

                    Parameter options

                    Hash of options

                  function options

                  options: (options: MarkedOptions) => typeof marked;
                  • Sets the default options.

                    Parameter options

                    Hash of options

                  function parse

                  parse: {
                  (src: string, callback: (error: any, parseResult: string) => void): string;
                  (
                  src: string,
                  options?: MarkedOptions,
                  callback?: (error: any, parseResult: string) => void
                  ): string;
                  };
                  • Compiles markdown to HTML.

                    Parameter src

                    String of markdown source to be compiled

                    Parameter callback

                    Function called when the markdownString has been fully parsed when using async highlighting String of compiled HTML

                  • Compiles markdown to HTML.

                    Parameter src

                    String of markdown source to be compiled

                    Parameter options

                    Hash of options

                    Parameter callback

                    Function called when the markdownString has been fully parsed when using async highlighting String of compiled HTML

                  function parseInline

                  parseInline: (src: string, options?: MarkedOptions) => string;
                  • Compiles markdown to HTML without enclosing p tag.

                    Parameter src

                    String of markdown source to be compiled

                    Parameter options

                    Hash of options String of compiled HTML

                  function parser

                  parser: (src: Token[] | TokensList, options?: MarkedOptions) => string;
                  • Parameter src

                    Tokenized source as array of tokens

                    Parameter options

                    Hash of options

                  function setOptions

                  setOptions: (options: MarkedOptions) => typeof marked;
                  • Sets the default options.

                    Parameter options

                    Hash of options

                  function use

                  use: (...extensions: MarkedExtension[]) => void;
                  • Use Extension

                    Parameter MarkedExtension

                  function walkTokens

                  walkTokens: (
                  tokens: Token[] | TokensList,
                  callback: (token: Token) => void
                  ) => typeof marked;

                    class Lexer

                    class Lexer {}

                      constructor

                      constructor(options?: MarkedOptions);

                        property options

                        options: MarkedOptions;

                          property rules

                          static rules: Rules;

                            property rules

                            rules: Rules;

                              property state

                              state: { inLink: boolean; inRawBlock: boolean; top: boolean };

                                property tokens

                                tokens: Token[] & { links: { [key: string]: { href: string; title: string } } };

                                  method blockTokens

                                  blockTokens: {
                                  (src: string, tokens: Token[]): Token[];
                                  (src: string, tokens: TokensList): TokensList;
                                  };

                                    method inline

                                    inline: (src: string, tokens: Token[]) => void;

                                      method inlineTokens

                                      inlineTokens: (src: string, tokens: Token[]) => Token[];

                                        method lex

                                        static lex: (src: string, options?: MarkedOptions) => TokensList;

                                          method lexInline

                                          static lexInline: (src: string, options?: MarkedOptions) => Token[];

                                            class Parser

                                            class Parser {}

                                              constructor

                                              constructor(options?: MarkedOptions);

                                                property options

                                                options: MarkedOptions;

                                                  property renderer

                                                  renderer: Renderer<never>;

                                                    property slugger

                                                    slugger: Slugger;

                                                      property textRenderer

                                                      textRenderer: TextRenderer;

                                                        property token

                                                        token: Token;

                                                          property tokens

                                                          tokens: TokensList | Token[];

                                                            method next

                                                            next: () => Token;

                                                              method parse

                                                              static parse: (src: Token[] | TokensList, options?: MarkedOptions) => string;

                                                                method parseInline

                                                                static parseInline: (src: Token[], options?: MarkedOptions) => string;

                                                                  class Renderer

                                                                  class Renderer<T = never> {}

                                                                    constructor

                                                                    constructor(options?: MarkedOptions);

                                                                      property options

                                                                      options: MarkedOptions;

                                                                        method blockquote

                                                                        blockquote: (this: RendererThis, quote: string) => string | T;

                                                                          method br

                                                                          br: (this: RendererThis) => string | T;

                                                                            method checkbox

                                                                            checkbox: (this: RendererThis, checked: boolean) => string | T;

                                                                              method code

                                                                              code: (
                                                                              this: RendererThis,
                                                                              code: string,
                                                                              language: string | undefined,
                                                                              isEscaped: boolean
                                                                              ) => string | T;

                                                                                method codespan

                                                                                codespan: (this: RendererThis, code: string) => string | T;

                                                                                  method del

                                                                                  del: (this: RendererThis, text: string) => string | T;

                                                                                    method em

                                                                                    em: (this: RendererThis, text: string) => string | T;

                                                                                      method heading

                                                                                      heading: (
                                                                                      this: RendererThis,
                                                                                      text: string,
                                                                                      level: 1 | 2 | 3 | 4 | 5 | 6,
                                                                                      raw: string,
                                                                                      slugger: Slugger
                                                                                      ) => string | T;

                                                                                        method hr

                                                                                        hr: (this: RendererThis) => string | T;

                                                                                          method html

                                                                                          html: (this: RendererThis, html: string) => string | T;

                                                                                            method image

                                                                                            image: (
                                                                                            this: RendererThis,
                                                                                            href: string | null,
                                                                                            title: string | null,
                                                                                            text: string
                                                                                            ) => string | T;
                                                                                              link: (
                                                                                              this: RendererThis,
                                                                                              href: string | null,
                                                                                              title: string | null,
                                                                                              text: string
                                                                                              ) => string | T;

                                                                                                method list

                                                                                                list: (
                                                                                                this: RendererThis,
                                                                                                body: string,
                                                                                                ordered: boolean,
                                                                                                start: number
                                                                                                ) => string | T;

                                                                                                  method listitem

                                                                                                  listitem: (
                                                                                                  this: RendererThis,
                                                                                                  text: string,
                                                                                                  task: boolean,
                                                                                                  checked: boolean
                                                                                                  ) => string | T;

                                                                                                    method paragraph

                                                                                                    paragraph: (this: RendererThis, text: string) => string | T;

                                                                                                      method strong

                                                                                                      strong: (this: RendererThis, text: string) => string | T;

                                                                                                        method table

                                                                                                        table: (this: RendererThis, header: string, body: string) => string | T;

                                                                                                          method tablecell

                                                                                                          tablecell: (
                                                                                                          this: RendererThis,
                                                                                                          content: string,
                                                                                                          flags: { header: boolean; align: 'center' | 'left' | 'right' | null }
                                                                                                          ) => string | T;

                                                                                                            method tablerow

                                                                                                            tablerow: (this: RendererThis, content: string) => string | T;

                                                                                                              method text

                                                                                                              text: (this: RendererThis, text: string) => string | T;

                                                                                                                class Slugger

                                                                                                                class Slugger {}

                                                                                                                  property seen

                                                                                                                  seen: { [slugValue: string]: number };

                                                                                                                    method slug

                                                                                                                    slug: (value: string, options?: SluggerOptions) => string;

                                                                                                                      class TextRenderer

                                                                                                                      class TextRenderer {}

                                                                                                                        method br

                                                                                                                        br: () => string;

                                                                                                                          method codespan

                                                                                                                          codespan: (text: string) => string;

                                                                                                                            method del

                                                                                                                            del: (text: string) => string;

                                                                                                                              method em

                                                                                                                              em: (text: string) => string;

                                                                                                                                method html

                                                                                                                                html: (text: string) => string;

                                                                                                                                  method image

                                                                                                                                  image: (href: string | null, title: string | null, text: string) => string;
                                                                                                                                    link: (href: string | null, title: string | null, text: string) => string;

                                                                                                                                      method strong

                                                                                                                                      strong: (text: string) => string;

                                                                                                                                        method text

                                                                                                                                        text: (text: string) => string;

                                                                                                                                          class Tokenizer

                                                                                                                                          class Tokenizer<T = never> {}

                                                                                                                                            constructor

                                                                                                                                            constructor(options?: MarkedOptions);

                                                                                                                                              property options

                                                                                                                                              options: MarkedOptions;
                                                                                                                                                autolink: (
                                                                                                                                                this: TokenizerThis,
                                                                                                                                                src: string,
                                                                                                                                                mangle: (cap: string) => string
                                                                                                                                                ) => Tokens.Link | T;

                                                                                                                                                  method blockquote

                                                                                                                                                  blockquote: (this: TokenizerThis, src: string) => Tokens.Blockquote | T;

                                                                                                                                                    method br

                                                                                                                                                    br: (this: TokenizerThis, src: string) => Tokens.Br | T;

                                                                                                                                                      method code

                                                                                                                                                      code: (this: TokenizerThis, src: string) => Tokens.Code | T;

                                                                                                                                                        method codespan

                                                                                                                                                        codespan: (this: TokenizerThis, src: string) => Tokens.Codespan | T;

                                                                                                                                                          method def

                                                                                                                                                          def: (this: TokenizerThis, src: string) => Tokens.Def | T;

                                                                                                                                                            method del

                                                                                                                                                            del: (this: TokenizerThis, src: string) => Tokens.Del | T;

                                                                                                                                                              method emStrong

                                                                                                                                                              emStrong: (
                                                                                                                                                              this: TokenizerThis,
                                                                                                                                                              src: string,
                                                                                                                                                              maskedSrc: string,
                                                                                                                                                              prevChar: string
                                                                                                                                                              ) => Tokens.Em | Tokens.Strong | T;

                                                                                                                                                                method escape

                                                                                                                                                                escape: (this: TokenizerThis, src: string) => Tokens.Escape | T;

                                                                                                                                                                  method fences

                                                                                                                                                                  fences: (this: TokenizerThis, src: string) => Tokens.Code | T;

                                                                                                                                                                    method heading

                                                                                                                                                                    heading: (this: TokenizerThis, src: string) => Tokens.Heading | T;

                                                                                                                                                                      method hr

                                                                                                                                                                      hr: (this: TokenizerThis, src: string) => Tokens.Hr | T;

                                                                                                                                                                        method html

                                                                                                                                                                        html: (this: TokenizerThis, src: string) => Tokens.HTML | T;

                                                                                                                                                                          method inlineText

                                                                                                                                                                          inlineText: (
                                                                                                                                                                          this: TokenizerThis,
                                                                                                                                                                          src: string,
                                                                                                                                                                          smartypants: (cap: string) => string
                                                                                                                                                                          ) => Tokens.Text | T;

                                                                                                                                                                            method lheading

                                                                                                                                                                            lheading: (this: TokenizerThis, src: string) => Tokens.Heading | T;
                                                                                                                                                                              link: (this: TokenizerThis, src: string) => Tokens.Image | Tokens.Link | T;

                                                                                                                                                                                method list

                                                                                                                                                                                list: (this: TokenizerThis, src: string) => Tokens.List | T;

                                                                                                                                                                                  method paragraph

                                                                                                                                                                                  paragraph: (this: TokenizerThis, src: string) => Tokens.Paragraph | T;
                                                                                                                                                                                    reflink: (
                                                                                                                                                                                    this: TokenizerThis,
                                                                                                                                                                                    src: string,
                                                                                                                                                                                    links: Tokens.Link[] | Tokens.Image[]
                                                                                                                                                                                    ) => Tokens.Link | Tokens.Image | Tokens.Text | T;

                                                                                                                                                                                      method space

                                                                                                                                                                                      space: (this: TokenizerThis, src: string) => Tokens.Space | T;

                                                                                                                                                                                        method table

                                                                                                                                                                                        table: (this: TokenizerThis, src: string) => Tokens.Table | T;

                                                                                                                                                                                          method tag

                                                                                                                                                                                          tag: (this: TokenizerThis, src: string) => Tokens.Tag | T;

                                                                                                                                                                                            method text

                                                                                                                                                                                            text: (this: TokenizerThis, src: string) => Tokens.Text | T;

                                                                                                                                                                                              method url

                                                                                                                                                                                              url: (
                                                                                                                                                                                              this: TokenizerThis,
                                                                                                                                                                                              src: string,
                                                                                                                                                                                              mangle: (cap: string) => string
                                                                                                                                                                                              ) => Tokens.Link | T;

                                                                                                                                                                                                interface MarkedExtension

                                                                                                                                                                                                interface MarkedExtension {}

                                                                                                                                                                                                  property baseUrl

                                                                                                                                                                                                  baseUrl?: string | undefined;
                                                                                                                                                                                                  • A prefix URL for any relative link.

                                                                                                                                                                                                  property breaks

                                                                                                                                                                                                  breaks?: boolean | undefined;
                                                                                                                                                                                                  • Enable GFM line breaks. This option requires the gfm option to be true.

                                                                                                                                                                                                  property extensions

                                                                                                                                                                                                  extensions?:
                                                                                                                                                                                                  | Array<
                                                                                                                                                                                                  | TokenizerExtension
                                                                                                                                                                                                  | RendererExtension
                                                                                                                                                                                                  | (TokenizerExtension & RendererExtension)
                                                                                                                                                                                                  >
                                                                                                                                                                                                  | undefined;
                                                                                                                                                                                                  • Add tokenizers and renderers to marked

                                                                                                                                                                                                  property gfm

                                                                                                                                                                                                  gfm?: boolean | undefined;
                                                                                                                                                                                                  • Enable GitHub flavored markdown.

                                                                                                                                                                                                  property headerIds

                                                                                                                                                                                                  headerIds?: boolean | undefined;
                                                                                                                                                                                                  • Include an id attribute when emitting headings.

                                                                                                                                                                                                  property headerPrefix

                                                                                                                                                                                                  headerPrefix?: string | undefined;
                                                                                                                                                                                                  • Set the prefix for header tag ids.

                                                                                                                                                                                                  property langPrefix

                                                                                                                                                                                                  langPrefix?: string | undefined;
                                                                                                                                                                                                  • Set the prefix for code block classes.

                                                                                                                                                                                                  property mangle

                                                                                                                                                                                                  mangle?: boolean | undefined;
                                                                                                                                                                                                  • Mangle autolinks (<email@domain.com>).

                                                                                                                                                                                                  property pedantic

                                                                                                                                                                                                  pedantic?: boolean | undefined;
                                                                                                                                                                                                  • Conform to obscure parts of markdown.pl as much as possible. Don't fix any of the original markdown bugs or poor behavior.

                                                                                                                                                                                                  property renderer

                                                                                                                                                                                                  renderer?: Renderer | RendererObject | undefined;
                                                                                                                                                                                                  • Type: object Default: new Renderer()

                                                                                                                                                                                                    An object containing functions to render tokens to HTML.

                                                                                                                                                                                                  property sanitize

                                                                                                                                                                                                  sanitize?: boolean | undefined;
                                                                                                                                                                                                  • Sanitize the output. Ignore any HTML that has been input.

                                                                                                                                                                                                  property silent

                                                                                                                                                                                                  silent?: boolean | undefined;
                                                                                                                                                                                                  • Shows an HTML error message when rendering fails.

                                                                                                                                                                                                  property smartLists

                                                                                                                                                                                                  smartLists?: boolean | undefined;
                                                                                                                                                                                                  • Use smarter list behavior than the original markdown. May eventually be default with the old behavior moved into pedantic.

                                                                                                                                                                                                  property smartypants

                                                                                                                                                                                                  smartypants?: boolean | undefined;
                                                                                                                                                                                                  • Use "smart" typograhic punctuation for things like quotes and dashes.

                                                                                                                                                                                                  property tokenizer

                                                                                                                                                                                                  tokenizer?: Tokenizer | TokenizerObject | undefined;
                                                                                                                                                                                                  • The tokenizer defines how to turn markdown text into tokens.

                                                                                                                                                                                                  property walkTokens

                                                                                                                                                                                                  walkTokens?: ((token: Token) => void) | undefined;
                                                                                                                                                                                                  • The walkTokens function gets called with every token. Child tokens are called before moving on to sibling tokens. Each token is passed by reference so updates are persisted when passed to the parser. The return value of the function is ignored.

                                                                                                                                                                                                  property xhtml

                                                                                                                                                                                                  xhtml?: boolean | undefined;
                                                                                                                                                                                                  • Generate closing slash for self-closing tags ( instead of )

                                                                                                                                                                                                  method highlight

                                                                                                                                                                                                  highlight: (
                                                                                                                                                                                                  code: string,
                                                                                                                                                                                                  lang: string,
                                                                                                                                                                                                  callback?: (error: any, code?: string) => void
                                                                                                                                                                                                  ) => string | void;
                                                                                                                                                                                                  • A function to highlight code blocks. The function can either be synchronous (returning a string) or asynchronous (callback invoked with an error if any occurred during highlighting and a string if highlighting was successful)

                                                                                                                                                                                                  method sanitizer

                                                                                                                                                                                                  sanitizer: (html: string) => string;
                                                                                                                                                                                                  • Optionally sanitize found HTML with a sanitizer function.

                                                                                                                                                                                                  interface MarkedOptions

                                                                                                                                                                                                  interface MarkedOptions extends Omit<MarkedExtension, 'extensions'> {}

                                                                                                                                                                                                    property renderer

                                                                                                                                                                                                    renderer?: Renderer | undefined;
                                                                                                                                                                                                    • Type: object Default: new Renderer()

                                                                                                                                                                                                      An object containing functions to render tokens to HTML.

                                                                                                                                                                                                    property tokenizer

                                                                                                                                                                                                    tokenizer?: Tokenizer | undefined;
                                                                                                                                                                                                    • The tokenizer defines how to turn markdown text into tokens.

                                                                                                                                                                                                    interface RendererExtension

                                                                                                                                                                                                    interface RendererExtension {}

                                                                                                                                                                                                      property name

                                                                                                                                                                                                      name: string;

                                                                                                                                                                                                        property renderer

                                                                                                                                                                                                        renderer: (this: RendererThis, token: Tokens.Generic) => string | false;

                                                                                                                                                                                                          interface RendererThis

                                                                                                                                                                                                          interface RendererThis {}

                                                                                                                                                                                                            property parser

                                                                                                                                                                                                            parser: Parser;

                                                                                                                                                                                                              interface Rules

                                                                                                                                                                                                              interface Rules {}

                                                                                                                                                                                                                index signature

                                                                                                                                                                                                                [ruleName: string]: RegExp | Rules;

                                                                                                                                                                                                                  interface SluggerOptions

                                                                                                                                                                                                                  interface SluggerOptions {}

                                                                                                                                                                                                                    property dryrun

                                                                                                                                                                                                                    dryrun: boolean;

                                                                                                                                                                                                                      interface TokenizerExtension

                                                                                                                                                                                                                      interface TokenizerExtension {}

                                                                                                                                                                                                                        property childTokens

                                                                                                                                                                                                                        childTokens?: string[] | undefined;

                                                                                                                                                                                                                          property level

                                                                                                                                                                                                                          level: 'block' | 'inline';

                                                                                                                                                                                                                            property name

                                                                                                                                                                                                                            name: string;

                                                                                                                                                                                                                              property start

                                                                                                                                                                                                                              start?: ((this: TokenizerThis, src: string) => number) | undefined;

                                                                                                                                                                                                                                property tokenizer

                                                                                                                                                                                                                                tokenizer: (
                                                                                                                                                                                                                                this: TokenizerThis,
                                                                                                                                                                                                                                src: string,
                                                                                                                                                                                                                                tokens: Token[] | TokensList
                                                                                                                                                                                                                                ) => Tokens.Generic | void;

                                                                                                                                                                                                                                  interface TokenizerThis

                                                                                                                                                                                                                                  interface TokenizerThis {}

                                                                                                                                                                                                                                    property lexer

                                                                                                                                                                                                                                    lexer: Lexer;

                                                                                                                                                                                                                                      type RendererObject

                                                                                                                                                                                                                                      type RendererObject = Partial<Omit<Renderer<false>, 'constructor' | 'options'>>;

                                                                                                                                                                                                                                        type Token

                                                                                                                                                                                                                                        type Token =
                                                                                                                                                                                                                                        | Tokens.Space
                                                                                                                                                                                                                                        | Tokens.Code
                                                                                                                                                                                                                                        | Tokens.Heading
                                                                                                                                                                                                                                        | Tokens.Table
                                                                                                                                                                                                                                        | Tokens.Hr
                                                                                                                                                                                                                                        | Tokens.Blockquote
                                                                                                                                                                                                                                        | Tokens.List
                                                                                                                                                                                                                                        | Tokens.ListItem
                                                                                                                                                                                                                                        | Tokens.Paragraph
                                                                                                                                                                                                                                        | Tokens.HTML
                                                                                                                                                                                                                                        | Tokens.Text
                                                                                                                                                                                                                                        | Tokens.Def
                                                                                                                                                                                                                                        | Tokens.Escape
                                                                                                                                                                                                                                        | Tokens.Tag
                                                                                                                                                                                                                                        | Tokens.Image
                                                                                                                                                                                                                                        | Tokens.Link
                                                                                                                                                                                                                                        | Tokens.Strong
                                                                                                                                                                                                                                        | Tokens.Em
                                                                                                                                                                                                                                        | Tokens.Codespan
                                                                                                                                                                                                                                        | Tokens.Br
                                                                                                                                                                                                                                        | Tokens.Del;

                                                                                                                                                                                                                                          type TokenizerObject

                                                                                                                                                                                                                                          type TokenizerObject = Partial<Omit<Tokenizer<false>, 'constructor' | 'options'>>;

                                                                                                                                                                                                                                            type TokensList

                                                                                                                                                                                                                                            type TokensList = Token[] & {
                                                                                                                                                                                                                                            links: {
                                                                                                                                                                                                                                            [key: string]: { href: string | null; title: string | null };
                                                                                                                                                                                                                                            };
                                                                                                                                                                                                                                            };

                                                                                                                                                                                                                                              namespace marked.Tokens

                                                                                                                                                                                                                                              namespace marked.Tokens {}

                                                                                                                                                                                                                                                interface Blockquote

                                                                                                                                                                                                                                                interface Blockquote {}

                                                                                                                                                                                                                                                  property raw

                                                                                                                                                                                                                                                  raw: string;

                                                                                                                                                                                                                                                    property text

                                                                                                                                                                                                                                                    text: string;

                                                                                                                                                                                                                                                      property tokens

                                                                                                                                                                                                                                                      tokens: Token[];

                                                                                                                                                                                                                                                        property type

                                                                                                                                                                                                                                                        type: 'blockquote';

                                                                                                                                                                                                                                                          interface Br

                                                                                                                                                                                                                                                          interface Br {}

                                                                                                                                                                                                                                                            property raw

                                                                                                                                                                                                                                                            raw: string;

                                                                                                                                                                                                                                                              property type

                                                                                                                                                                                                                                                              type: 'br';

                                                                                                                                                                                                                                                                interface Code

                                                                                                                                                                                                                                                                interface Code {}

                                                                                                                                                                                                                                                                  property codeBlockStyle

                                                                                                                                                                                                                                                                  codeBlockStyle?: 'indented' | undefined;

                                                                                                                                                                                                                                                                    property lang

                                                                                                                                                                                                                                                                    lang?: string | undefined;

                                                                                                                                                                                                                                                                      property raw

                                                                                                                                                                                                                                                                      raw: string;

                                                                                                                                                                                                                                                                        property text

                                                                                                                                                                                                                                                                        text: string;

                                                                                                                                                                                                                                                                          property type

                                                                                                                                                                                                                                                                          type: 'code';

                                                                                                                                                                                                                                                                            interface Codespan

                                                                                                                                                                                                                                                                            interface Codespan {}

                                                                                                                                                                                                                                                                              property raw

                                                                                                                                                                                                                                                                              raw: string;

                                                                                                                                                                                                                                                                                property text

                                                                                                                                                                                                                                                                                text: string;

                                                                                                                                                                                                                                                                                  property type

                                                                                                                                                                                                                                                                                  type: 'codespan';

                                                                                                                                                                                                                                                                                    interface Def

                                                                                                                                                                                                                                                                                    interface Def {}

                                                                                                                                                                                                                                                                                      property href

                                                                                                                                                                                                                                                                                      href: string;

                                                                                                                                                                                                                                                                                        property raw

                                                                                                                                                                                                                                                                                        raw: string;

                                                                                                                                                                                                                                                                                          property tag

                                                                                                                                                                                                                                                                                          tag: string;

                                                                                                                                                                                                                                                                                            property title

                                                                                                                                                                                                                                                                                            title: string;

                                                                                                                                                                                                                                                                                              property type

                                                                                                                                                                                                                                                                                              type: 'def';

                                                                                                                                                                                                                                                                                                interface Del

                                                                                                                                                                                                                                                                                                interface Del {}

                                                                                                                                                                                                                                                                                                  property raw

                                                                                                                                                                                                                                                                                                  raw: string;

                                                                                                                                                                                                                                                                                                    property text

                                                                                                                                                                                                                                                                                                    text: string;

                                                                                                                                                                                                                                                                                                      property tokens

                                                                                                                                                                                                                                                                                                      tokens: Token[];

                                                                                                                                                                                                                                                                                                        property type

                                                                                                                                                                                                                                                                                                        type: 'del';

                                                                                                                                                                                                                                                                                                          interface Em

                                                                                                                                                                                                                                                                                                          interface Em {}

                                                                                                                                                                                                                                                                                                            property raw

                                                                                                                                                                                                                                                                                                            raw: string;

                                                                                                                                                                                                                                                                                                              property text

                                                                                                                                                                                                                                                                                                              text: string;

                                                                                                                                                                                                                                                                                                                property tokens

                                                                                                                                                                                                                                                                                                                tokens: Token[];

                                                                                                                                                                                                                                                                                                                  property type

                                                                                                                                                                                                                                                                                                                  type: 'em';

                                                                                                                                                                                                                                                                                                                    interface Escape

                                                                                                                                                                                                                                                                                                                    interface Escape {}

                                                                                                                                                                                                                                                                                                                      property raw

                                                                                                                                                                                                                                                                                                                      raw: string;

                                                                                                                                                                                                                                                                                                                        property text

                                                                                                                                                                                                                                                                                                                        text: string;

                                                                                                                                                                                                                                                                                                                          property type

                                                                                                                                                                                                                                                                                                                          type: 'escape';

                                                                                                                                                                                                                                                                                                                            interface Generic

                                                                                                                                                                                                                                                                                                                            interface Generic {}

                                                                                                                                                                                                                                                                                                                              property raw

                                                                                                                                                                                                                                                                                                                              raw: string;

                                                                                                                                                                                                                                                                                                                                property tokens

                                                                                                                                                                                                                                                                                                                                tokens?: Token[] | undefined;

                                                                                                                                                                                                                                                                                                                                  property type

                                                                                                                                                                                                                                                                                                                                  type: string;

                                                                                                                                                                                                                                                                                                                                    index signature

                                                                                                                                                                                                                                                                                                                                    [index: string]: any;

                                                                                                                                                                                                                                                                                                                                      interface Heading

                                                                                                                                                                                                                                                                                                                                      interface Heading {}

                                                                                                                                                                                                                                                                                                                                        property depth

                                                                                                                                                                                                                                                                                                                                        depth: number;

                                                                                                                                                                                                                                                                                                                                          property raw

                                                                                                                                                                                                                                                                                                                                          raw: string;

                                                                                                                                                                                                                                                                                                                                            property text

                                                                                                                                                                                                                                                                                                                                            text: string;

                                                                                                                                                                                                                                                                                                                                              property tokens

                                                                                                                                                                                                                                                                                                                                              tokens: Token[];

                                                                                                                                                                                                                                                                                                                                                property type

                                                                                                                                                                                                                                                                                                                                                type: 'heading';

                                                                                                                                                                                                                                                                                                                                                  interface Hr

                                                                                                                                                                                                                                                                                                                                                  interface Hr {}

                                                                                                                                                                                                                                                                                                                                                    property raw

                                                                                                                                                                                                                                                                                                                                                    raw: string;

                                                                                                                                                                                                                                                                                                                                                      property type

                                                                                                                                                                                                                                                                                                                                                      type: 'hr';

                                                                                                                                                                                                                                                                                                                                                        interface HTML

                                                                                                                                                                                                                                                                                                                                                        interface HTML {}

                                                                                                                                                                                                                                                                                                                                                          property pre

                                                                                                                                                                                                                                                                                                                                                          pre: boolean;

                                                                                                                                                                                                                                                                                                                                                            property raw

                                                                                                                                                                                                                                                                                                                                                            raw: string;

                                                                                                                                                                                                                                                                                                                                                              property text

                                                                                                                                                                                                                                                                                                                                                              text: string;

                                                                                                                                                                                                                                                                                                                                                                property type

                                                                                                                                                                                                                                                                                                                                                                type: 'html';

                                                                                                                                                                                                                                                                                                                                                                  interface Image

                                                                                                                                                                                                                                                                                                                                                                  interface Image {}

                                                                                                                                                                                                                                                                                                                                                                    property href

                                                                                                                                                                                                                                                                                                                                                                    href: string;

                                                                                                                                                                                                                                                                                                                                                                      property raw

                                                                                                                                                                                                                                                                                                                                                                      raw: string;

                                                                                                                                                                                                                                                                                                                                                                        property text

                                                                                                                                                                                                                                                                                                                                                                        text: string;

                                                                                                                                                                                                                                                                                                                                                                          property title

                                                                                                                                                                                                                                                                                                                                                                          title: string;

                                                                                                                                                                                                                                                                                                                                                                            property type

                                                                                                                                                                                                                                                                                                                                                                            type: 'image';
                                                                                                                                                                                                                                                                                                                                                                              interface Link {}

                                                                                                                                                                                                                                                                                                                                                                                property href

                                                                                                                                                                                                                                                                                                                                                                                href: string;

                                                                                                                                                                                                                                                                                                                                                                                  property raw

                                                                                                                                                                                                                                                                                                                                                                                  raw: string;

                                                                                                                                                                                                                                                                                                                                                                                    property text

                                                                                                                                                                                                                                                                                                                                                                                    text: string;

                                                                                                                                                                                                                                                                                                                                                                                      property title

                                                                                                                                                                                                                                                                                                                                                                                      title: string;

                                                                                                                                                                                                                                                                                                                                                                                        property tokens

                                                                                                                                                                                                                                                                                                                                                                                        tokens: Token[];

                                                                                                                                                                                                                                                                                                                                                                                          property type

                                                                                                                                                                                                                                                                                                                                                                                          type: 'link';

                                                                                                                                                                                                                                                                                                                                                                                            interface List

                                                                                                                                                                                                                                                                                                                                                                                            interface List {}

                                                                                                                                                                                                                                                                                                                                                                                              property items

                                                                                                                                                                                                                                                                                                                                                                                              items: ListItem[];

                                                                                                                                                                                                                                                                                                                                                                                                property loose

                                                                                                                                                                                                                                                                                                                                                                                                loose: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                  property ordered

                                                                                                                                                                                                                                                                                                                                                                                                  ordered: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                    property raw

                                                                                                                                                                                                                                                                                                                                                                                                    raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                      property start

                                                                                                                                                                                                                                                                                                                                                                                                      start: number | '';

                                                                                                                                                                                                                                                                                                                                                                                                        property type

                                                                                                                                                                                                                                                                                                                                                                                                        type: 'list';

                                                                                                                                                                                                                                                                                                                                                                                                          interface ListItem

                                                                                                                                                                                                                                                                                                                                                                                                          interface ListItem {}

                                                                                                                                                                                                                                                                                                                                                                                                            property checked

                                                                                                                                                                                                                                                                                                                                                                                                            checked?: boolean | undefined;

                                                                                                                                                                                                                                                                                                                                                                                                              property loose

                                                                                                                                                                                                                                                                                                                                                                                                              loose: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                property raw

                                                                                                                                                                                                                                                                                                                                                                                                                raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                                  property task

                                                                                                                                                                                                                                                                                                                                                                                                                  task: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                    property text

                                                                                                                                                                                                                                                                                                                                                                                                                    text: string;

                                                                                                                                                                                                                                                                                                                                                                                                                      property tokens

                                                                                                                                                                                                                                                                                                                                                                                                                      tokens: Token[];

                                                                                                                                                                                                                                                                                                                                                                                                                        property type

                                                                                                                                                                                                                                                                                                                                                                                                                        type: 'list_item';

                                                                                                                                                                                                                                                                                                                                                                                                                          interface Paragraph

                                                                                                                                                                                                                                                                                                                                                                                                                          interface Paragraph {}

                                                                                                                                                                                                                                                                                                                                                                                                                            property pre

                                                                                                                                                                                                                                                                                                                                                                                                                            pre?: boolean | undefined;

                                                                                                                                                                                                                                                                                                                                                                                                                              property raw

                                                                                                                                                                                                                                                                                                                                                                                                                              raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                property text

                                                                                                                                                                                                                                                                                                                                                                                                                                text: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                  property tokens

                                                                                                                                                                                                                                                                                                                                                                                                                                  tokens: Token[];

                                                                                                                                                                                                                                                                                                                                                                                                                                    property type

                                                                                                                                                                                                                                                                                                                                                                                                                                    type: 'paragraph';

                                                                                                                                                                                                                                                                                                                                                                                                                                      interface Space

                                                                                                                                                                                                                                                                                                                                                                                                                                      interface Space {}

                                                                                                                                                                                                                                                                                                                                                                                                                                        property raw

                                                                                                                                                                                                                                                                                                                                                                                                                                        raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                          property type

                                                                                                                                                                                                                                                                                                                                                                                                                                          type: 'space';

                                                                                                                                                                                                                                                                                                                                                                                                                                            interface Strong

                                                                                                                                                                                                                                                                                                                                                                                                                                            interface Strong {}

                                                                                                                                                                                                                                                                                                                                                                                                                                              property raw

                                                                                                                                                                                                                                                                                                                                                                                                                                              raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                property text

                                                                                                                                                                                                                                                                                                                                                                                                                                                text: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                  property tokens

                                                                                                                                                                                                                                                                                                                                                                                                                                                  tokens: Token[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                    property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                    type: 'strong';

                                                                                                                                                                                                                                                                                                                                                                                                                                                      interface Table

                                                                                                                                                                                                                                                                                                                                                                                                                                                      interface Table {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                        property align

                                                                                                                                                                                                                                                                                                                                                                                                                                                        align: Array<'center' | 'left' | 'right' | null>;

                                                                                                                                                                                                                                                                                                                                                                                                                                                          property header

                                                                                                                                                                                                                                                                                                                                                                                                                                                          header: TableCell[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                            property raw

                                                                                                                                                                                                                                                                                                                                                                                                                                                            raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                              property rows

                                                                                                                                                                                                                                                                                                                                                                                                                                                              rows: TableCell[][];

                                                                                                                                                                                                                                                                                                                                                                                                                                                                property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                type: 'table';

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  interface TableCell

                                                                                                                                                                                                                                                                                                                                                                                                                                                                  interface TableCell {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    property text

                                                                                                                                                                                                                                                                                                                                                                                                                                                                    text: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property tokens

                                                                                                                                                                                                                                                                                                                                                                                                                                                                      tokens: Token[];

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        interface Tag

                                                                                                                                                                                                                                                                                                                                                                                                                                                                        interface Tag {}
                                                                                                                                                                                                                                                                                                                                                                                                                                                                          inLink: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property inRawBlock

                                                                                                                                                                                                                                                                                                                                                                                                                                                                            inRawBlock: boolean;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              property raw

                                                                                                                                                                                                                                                                                                                                                                                                                                                                              raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                property text

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                text: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                  type: 'text' | 'html';

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface Text

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                    interface Text {}

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      property raw

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                      raw: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        property text

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                        text: string;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          property tokens

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          tokens?: Token[] | undefined;

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            property type

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                            type: 'text';

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Package Files (1)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Dependencies (0)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              No dependencies.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Dev Dependencies (0)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              No dev dependencies.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Peer Dependencies (0)

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              No peer dependencies.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              Badge

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              To add a badge like this onejsDocs.io badgeto your package's README, use the codes available below.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@types/marked.

                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • Markdown
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                [![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@types/marked)
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              • HTML
                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                <a href="https://www.jsdocs.io/package/@types/marked"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>