October 3, 2022 — JavaScript API built-in module and request body updates
We've made updates to the EdgeWorkers JavaScript API built-in modules and expanded support for ReadableStreams in the contents of the request body.
-
You can now reference public keys locally within your EdgeWorkers code bundle and pass them into the crypto built-in module. Crypto libraries, such as crypto-es, no longer need to be packed locally into the EdgeWorkers code bundle.
-
The encoding built-in module now supports
atob()
, andbtoa()
in your EdgeWorkers code bundles to handle text in various character encodings, including legacy non-UTF-8. -
The
Request Object
now supports abody
property. This read-only ReadableStream value is used to read the contents of the request body. It is only available when using theresponseProvider
event. -
The body property of the
httpRequest()
function now supports ReadableStreams in the contents of the request body.