Web platform APIs
13 features: 4 implemented, 1 partial, 8 planned. Back to all areas.
| Feature | Status | What works | Test |
|---|---|---|---|
AbortController | planned | From the DOM standard, "Interface AbortController"; a built-in of d-web-platform, not built yet. | |
AbortSignal | planned | From the DOM standard, "Interface AbortSignal"; a built-in of d-web-platform, not built yet. | |
atob | implemented | The HTML standard's atob, by Infra's forgiving-base64 decode: ASCII whitespace is ignored, padding is optional, and text that is not base64 throws a DOMException named InvalidCharacterError. The result is a string of code units 0 to 255. Tested with the Web Platform Tests' fetch/data-urls/resources/base64.json (wpt/run.sh). | tests/web.js |
btoa | implemented | The HTML standard's btoa: a string of code units 0 to 255 as base64 with padding; a code unit above 255 throws a DOMException named InvalidCharacterError. | tests/web.js |
DOMException | implemented | WebIDL's DOMException: a global constructor of (message, name) whose prototype inherits Error.prototype, with the getters name, message and code (the legacy code table), @@toStringTag "DOMException", and the legacy code constants on the constructor and the prototype. An instance is a branded record (Error.isError gives true): a 128-byte record holding its name and message, and a 24-byte handle slot. The web-platform built-ins throw it: atob's and btoa's InvalidCharacterError. A DOMException is not serializable yet (structuredClone does not exist). | tests/web.js |
Headers | planned | From the Fetch standard, "Headers class"; a built-in of d-web-platform, not built yet. | |
Request | planned | From the Fetch standard, "Request class"; a built-in of d-web-platform, not built yet. | |
Response | planned | From the Fetch standard, "Response class"; a built-in of d-web-platform, not built yet. | |
structuredClone | planned | From the HTML standard, "structuredClone"; a built-in of d-web-platform, not built yet. | |
TextDecoder | partial | The Encoding standard's TextDecoder for UTF-8, UTF-16LE and UTF-16BE, with the fatal and ignoreBOM options and streaming decode; every label of the standard resolves, and the other encodings are refused as unsupported, by name. Tested with the Web Platform Tests' encoding/resources/encodings.js (wpt/run.sh), whose entries for the other encodings are expected to fail. An instance is a branded record: a 136-byte record (its encoding, flags and decoder state) and a 24-byte handle slot. | tests/encoding.js |
TextEncoder | implemented | The Encoding standard's TextEncoder: encode and encodeInto, to UTF-8, and the encoding getter, over Object.prototype with @@toStringTag "TextEncoder". An instance is a branded record with no state of its own: a 112-byte record and a 24-byte handle slot. | tests/encoding.js |
URL | planned | From the URL standard, "URL class"; a built-in of d-web-platform, not built yet. | |
URLSearchParams | planned | From the URL standard, "Interface URLSearchParams"; a built-in of d-web-platform, not built yet. |
0c5984ec; each test is a program that runs the feature.