Minor Changes
-
Answer a
Rangeheader with more than one range with206 Partial Contentand amultipart/byterangesbody, instead of the whole file. Each part carries its ownContent-TypeandContent-Range; ranges that overlap or touch are merged first, and the parts come in the order the ranges were asked for. When the output file system can stream, each range is read on its own, so asking for a few slices of a large asset reads only those; withoutcreateReadStream, or when a strongETaghas already read the file, the parts are cut from the whole file. A request for more than 200 ranges gets the whole file, as before.modifyResponseDatareceives that body as aReadable, so itsdata(and thedatait returns) is typedBuffer | Readable, which still includes aReadStream. (by @alexander-akait in #2496) -
The overlay sends the client's token along when it asks
openEditorEndpointto open a file, so a server can tell the overlay's request from one another page made. Only to an endpoint on the page's own server (a rooted path), never to an absolute url, and only when the client was given a token. (by @alexander-akait in #2488)
Patch Changes
-
Read the page's own url parameters without writing a property named after each one. A parameter such as
__proto__orconstructoris now looked through like any other instead of becoming a property name to write; behavior is otherwise unchanged. (by @alexander-akait in #2494) -
Fix initialization with rspack, whose
compiler.hooksthrows when reading thevalidatehook it doesn't implement. (by @Cherry in #2503) -
Expose the existing
devMiddlewareproperty in the Koa and Hono wrapper return types, preserving custom request and response types. (by @MehdiZare in #2489)