Comments (3)
@barthelemypousset, there's no easy way how to change this in one place currently, you would have to change this in concrete calls to html.escape()
within the HTMLRenderer
class.
mistletoe historically escapes quotes ("
) and since version 0.9.0 we also escape apostrophes ('
; see #115 and ef9bd3a). But I can see this doesn't always have to be desired, so I think it would be cool to have the escaping as an option (or options) in a future version of mistletoe. Now 1.0.0 is about to be released, so I would plan this to 1.1.0.
Cc @anderskaplan. :)
from mistletoe.
@barthelemypousset (and @anderskaplan), something like in the created PR draft?
Regarding making the escaping of both double and single quotes disabled by default (not for attributes though, of course!), I'm not personally against that. I always prefer simpler things if there is no evident con (and "something"
is definitely more readable and shorter than "something"
). It would just require I hope a simple change to the commonmark.py test file, so that tests still pass.
from mistletoe.
Related Issues (20)
- Failure to parse paragraph containing just "[" HOT 4
- Make tables GFM-compliant - support less than 3 dashes in delimiters HOT 1
- Blocks in between footlink definitions are skipped when parsing HOT 3
- Parsing error in a specific case HOT 3
- TypeError: 'str' object is not an iterator, when using example in docs HOT 2
- **`what`:** gives odd output HOT 3
- Support of Smart punctuation / Simple typographic replacements HOT 3
- 0.8.2: pytest is failing in `test/test_contrib/test_github_wiki.py::TestGithubWiki::test_parse` unit and `DeprecationWarning` warnings HOT 5
- Record line numbers on tokens HOT 6
- Unused imports HOT 1
- question: how to render AST back to a markdown string HOT 1
- LaTeX renderer does not handle inline code with vertical bars correctly HOT 2
- pikchr integration? HOT 1
- Question: Inconsistencies in the block tokens HOT 2
- Enable tables which interrupt a paragraph (like GFM does) HOT 5
- IndexError on malformed markdown tables HOT 1
- Emphasis around link ignored when followed by a special punctuation character HOT 1
- Contrib sub-package is missing in the mistletoe 1.0.0 PyPI version HOT 3
- Question how to modify ast and write back out as markdown HOT 4
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mistletoe.