You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is probably a documentation issue more than anything else. When configuring Markdown, the first instinct is probably to use a configured markdown.Markdown instance in MARKUP_FIELD_TYPES. However, Markdown instances need to be explicitly reset (Markdown.reset()) after rendering to avoid issues such as this Python-Markdown/markdown#401 (I tripped on this, so here I am).
markdown.markdown handles this automatically, so the proper way, probably, to go about this is to use django.utils.functional.curry (or own similar function) to wrap it (like you do when you're adding Pygments extension) and add configuration in MARKUP_FIELD_TYPES. This should probably be mentioned in documentation.
The text was updated successfully, but these errors were encountered:
This is probably a documentation issue more than anything else. When configuring Markdown, the first instinct is probably to use a configured
markdown.Markdown
instance inMARKUP_FIELD_TYPES
. However, Markdown instances need to be explicitly reset (Markdown.reset()
) after rendering to avoid issues such as this Python-Markdown/markdown#401 (I tripped on this, so here I am).markdown.markdown
handles this automatically, so the proper way, probably, to go about this is to usedjango.utils.functional.curry
(or own similar function) to wrap it (like you do when you're adding Pygments extension) and add configuration inMARKUP_FIELD_TYPES
. This should probably be mentioned in documentation.The text was updated successfully, but these errors were encountered: