edgedb-js
edgedb-js copied to clipboard
Consider packaging the driver for different runtimes
We currently target two runtimes (Node and Deno) by doing some build time transformations. There are now more possible runtimes that we could target and take advantage of platform-specific APIs or other runtime-specific concerns (like envrionment variables on Cloudflare or Bun.connect() for Bun). We should consider perhaps providing separate packages for each runtime that takes advantage of these opportunities.
Some possible runtime targets:
- (existing) Node.js
- (existing) Browser
- (existing) Deno
- Bun
- Cloudflare Workers (workerd)
- WinterCG (is this a legible target?)
Open Questions
- How would the
@edgedb/generatepackage depend on these packages?- Maybe through optional
peerDependencies?
- Maybe through optional