MCPcopy Create free account
hub / github.com/Python-Markdown/markdown / AncestorExtension

Class AncestorExtension

tests/test_apis.py:1002–1013  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1000 return el, m.start(0), m.end(0)
1001
1002 class AncestorExtension(markdown.Extension):
1003
1004 def __init__(self, *args, **kwargs):
1005 """Initialize."""
1006
1007 self.config = {}
1008
1009 def extendMarkdown(self, md):
1010 """Modify inline patterns."""
1011
1012 pattern = r'(\+)([^\+]+)\1'
1013 md.inlinePatterns.register(TestAncestorExclusion.AncestorExample(pattern, 'strong'), 'ancestor-test', 0)
1014
1015 def setUp(self):
1016 """Setup markdown object."""

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected