summaryrefslogtreecommitdiffstats
path: root/testing/web-platform/tests/interfaces/sanitizer-api.tentative.idl
blob: 3e843d8eb0cbcc448010dd6a56d3a2ecd1321314 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// https://wicg.github.io/sanitizer-api/

[
  Exposed=Window,
  SecureContext
] interface Sanitizer {
  constructor(optional SanitizerConfig sanitizerConfig = {});
  DocumentFragment sanitize((DocumentFragment or Document) input);
};

dictionary SanitizerConfig {
  sequence<DOMString> allowElements;
  sequence<DOMString> blockElements;
  sequence<DOMString> dropElements;
  sequence<DOMString> allowAttributes;
  sequence<DOMString> dropAttributes;
};