Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add an HTML 'safeMode' flag #61

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

jimstudt
Copy link
Contributor

Add a flag to MarkdownParser( safeMode: Bool = false) which prevents HTML in the input from getting to the output.

This is useful if you publish user generated content. The HTML angle brackets are encoded as HTML entities so the tags are visible in the output HTML, but won't be active.

Notice there were two places we had to recognize safeMode when reading a "<" and choose to use SafedHTML.

…HTML on the input from getting to the HTML output.

This is useful if you publish user generated content.
Notice there were two places we had to recognize safeMode when reading a "<" and choose to use SafedHTML.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant