const writableStream = new WritableStream({
start(controller) {
// do stuff with controller
// error stream if necessary
controller.error("My stream is broken");
},
write(chunk, controller) {
// …
},
close() {
// …
},
abort(err) {
// …
},
});WritableStreamDefaultController / notebook
WritableStreamDefaultController
Runnable notebook: every JavaScript, HTML and CSS example on this page executes in a sandboxed local frame. Nothing leaves the browser.