Parent: #473
Standards: https://fetch.spec.whatwg.org/#request-class and https://webidl.spec.whatwg.org/#js-dictionary
Problem
The exposed Request constructor currently accepts arbitrary cache/credentials/mode/redirect strings, accepts invalid or forbidden methods, reads supported RequestInit members outside Web IDL lexicographic order, stores integrity through physical StringData bytes, and resets inherited request state to defaults when constructing from another Request.
Scope
- Convert the currently exposed RequestInit members in Web IDL order: body, cache, credentials, headers, integrity, keepalive, method, mode, redirect.
- Enforce RequestCache, RequestCredentials, RequestMode, and RequestRedirect enum values.
- Enforce ByteString and HTTP token constraints for method, reject CONNECT/TRACE/TRACK, and normalize the six Fetch-normalized methods.
- Reject mode navigate and only-if-cached unless mode is same-origin.
- Canonicalize persistent DOMString integrity.
- Preserve cache/credentials/mode/redirect/integrity/keepalive when constructing from an existing Request unless init overrides them.
- Preserve exact getter/coercion order and abrupt completion.
This issue does not touch promises, jobs, queues, workers/threads, or Map/Set iterators.
Acceptance
- Valid state round-trips and inherited Request construction preserves it.
- Invalid enum, ByteString, token, forbidden-method, navigate, and cache/mode combinations throw TypeError.
- Supported dictionary getters run once in lexicographic order.
- Integrity survives canonical and forced-flat physical StringData storage with one coercion.
- Focused Debug, ReleaseSafe, and TSan tests pass; full sharded units have zero failures/leaks.
- Test262 Web API coverage is inventoried explicitly; a zero denominator is no corpus claim.