Avoid corrupting Markdown URL with <, (, \ (v2) (#19482)

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
Co-authored-by: fisker <lionkay@gmail.com>
This commit is contained in:
Anders Kaseorgandfisker authored and GitHub committed 2026-08-15 18:24:23 +08:00
1 parent bee1399282
commit d753f4563d
4 files changed
+79 -28

No files matched your search

+15
View File
@@ -0,0 +1,15 @@
#### Avoid corrupting URL with `<`, `(`, `\` (#19482 by @andersk)
Avoid corrupting a link, image, or link reference definition with with certain characters like `<`, `(`, `\`, by using `<...>` wrapping and `\` escaping as appropriate.
<!-- prettier-ignore -->
```md
<!-- Input -->
[link](<\<(\\>)
<!-- Prettier stable -->
[link](<(\)
<!-- Prettier main -->
[link](<\<(\\>)
```