Skip to content

Interface: ParserOptions ​

Defined in: parser/parser.ts:11

Extended by ​

Properties ​

html? ​

ts
optional html: boolean;

Defined in: parser/parser.ts:18

Set true to enable HTML tags in source. Be careful! That's not safe! You may need external sanitizer to protect output from XSS. It's better to extend features via plugins, instead of enabling HTML.

Default ​

ts
false

linkify? ​

ts
optional linkify: boolean;

Defined in: parser/parser.ts:24

Set true to autoconvert URL-like text to links.

Default ​

ts
false

maxNesting? ​

ts
optional maxNesting: number;

Defined in: parser/parser.ts:45

Internal protection, recursion limit


quotes? ​

ts
optional quotes: string | string[];

Defined in: parser/parser.ts:40

Double + single quotes replacement pairs, when typographer enabled and smartquotes on. For example, you can use '«»„“' for Russian, '„“‚‘' for German, and ['«\xA0', '\xA0»', '‹\xA0', '\xA0›'] for French (including nbsp).

Default ​

ts
'“”‘’'

typographer? ​

ts
optional typographer: boolean;

Defined in: parser/parser.ts:31

Set true to enable some language-neutral replacement + quotes beautification (smartquotes).

Default ​

ts
false

Released under the MIT License.