‹› markdown.extensions.smarty

Adds conversion of ASCII dashes, quotes and ellipses to their HTML entity equivalents.

See the documentation for details.

‹› markdown.extensions.smarty.SubstituteTextPattern(pattern: str, replace: Sequence[int | str | etree.Element], md: Markdown)

‹› markdown.extensions.smarty.SmartyExtension(**kwargs)

Bases: Extension

Add Smarty to Markdown.

‹› markdown.extensions.smarty.SmartyExtension.config instance-attribute

Default configuration options.

Defined Value:

self.config = {
    'smart_quotes': [True, 'Educate quotes'],
    'smart_angled_quotes': [False, 'Educate angled quotes'],
    'smart_dashes': [True, 'Educate dashes'],
    'smart_ellipses': [True, 'Educate ellipses'],
    'substitutions': [{}, 'Overwrite default substitutions'],
}