Problem
Server-side ECMAScript runtimes currently expose environment variables, command-line arguments, and standard I/O through incompatible, runtime-specific APIs — Node.js uses process.env and process.argv, Deno uses Deno.env and Deno.args, and Cloudflare Workers provides no equivalent. This lack of a common standard makes cross-runtime code difficult to write and maintain. This proposal addresses that gap by defining a unified Environment API that works across runtimes and builds on existing web platform primitives such as ReadableStream and WritableStream wherever possible.
Specification
The document is available here. Please leave your thoughts and questions below to discuss this further.
Problem
Server-side ECMAScript runtimes currently expose environment variables, command-line arguments, and standard I/O through incompatible, runtime-specific APIs — Node.js uses process.env and process.argv, Deno uses Deno.env and Deno.args, and Cloudflare Workers provides no equivalent. This lack of a common standard makes cross-runtime code difficult to write and maintain. This proposal addresses that gap by defining a unified Environment API that works across runtimes and builds on existing web platform primitives such as ReadableStream and WritableStream wherever possible.
Specification
The document is available here. Please leave your thoughts and questions below to discuss this further.