Skip to content

Commit 1e4d02d

Browse files
foolipddbeck
andauthored
Add Document.parseHTMLUnsafe() and friends (#999)
Co-authored-by: Daniel D. Beck <[email protected]>
1 parent 2e89852 commit 1e4d02d

File tree

2 files changed

+28
-0
lines changed

2 files changed

+28
-0
lines changed
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Generated from: parse-html-unsafe.yml
2+
# Do not edit this file by hand. Edit the source file instead!
3+
4+
name: Unsanitized HTML parsing methods
5+
description: The `Document.parseHTMLUnsafe()` static method parses HTML into a DOM tree, while the `setHTMLUnsafe()` method of `Element` and `ShadowRoot` parses and inserts HTML into an existing tree. No sanitization applies to these methods, so never call them with user-provided HTML strings.
6+
spec: https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#unsafe-html-parsing-methods
7+
status:
8+
baseline: low
9+
baseline_low_date: 2024-04-18
10+
support:
11+
chrome: "124"
12+
chrome_android: "124"
13+
edge: "124"
14+
firefox: "123"
15+
firefox_android: "123"
16+
safari: "17.4"
17+
safari_ios: "17.4"
18+
compat_features:
19+
- api.Document.parseHTMLUnsafe_static
20+
- api.Element.setHTMLUnsafe
21+
- api.ShadowRoot.setHTMLUnsafe

features/parse-html-unsafe.yml

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
name: Unsanitized HTML parsing methods
2+
description: The `Document.parseHTMLUnsafe()` static method parses HTML into a DOM tree, while the `setHTMLUnsafe()` method of `Element` and `ShadowRoot` parses and inserts HTML into an existing tree. No sanitization applies to these methods, so never call them with user-provided HTML strings.
3+
spec: https://html.spec.whatwg.org/multipage/dynamic-markup-insertion.html#unsafe-html-parsing-methods
4+
compat_features:
5+
- api.Document.parseHTMLUnsafe_static
6+
- api.Element.setHTMLUnsafe
7+
- api.ShadowRoot.setHTMLUnsafe

0 commit comments

Comments
 (0)