@sanity/client
compatibility with JS runtimesYou should be able to use @sanity/client
from any runtime, including Cloudflare Workers, Deno, Bun, and more.
Status | Name | Runtime | Entry | Conditions | Adapter | Environment |
---|---|---|---|---|---|---|
Bun Canary | bun | exports.node.import+exports.node.require | bun, import, node, node.deno, node.import | fetch | browser | |
Bun Latest | bun | exports.node.import+exports.node.require | bun, import, node, node.deno, node.import | fetch | browser | |
Cloudflare Worker | cloudflare-worker | exports.browser | browser, import, worker, worker.browser | fetch | browser | |
Cloudflare Worker Node compatibility mode | cloudflare-worker | exports.browser | browser, import, worker, worker.browser | fetch | browser | |
Deno v1 npm specifier | deno | exports.deno | deno, import, node, node.deno, node.import | fetch | browser | |
Deno v1 Packages from CDN | deno | exports.deno | deno, import, module, worker, worker.browser, worker.node | fetch | browser | |
Next.js Edge Function | vercel-edge | exports.browser | browser, edge-light, import, module, webpack, worker, worker.browser | fetch | browser | |
Next.js Serverless Function | node | exports.node.import+exports.node.require | import, node, node.deno, node.import | node | node | |
Node.js CJS v14 | node | exports.require | node, node.require, require | node | node | |
Node.js CJS v16 | node | exports.require | node, node.require, require | node | node | |
Node.js CJS v18 | node | exports.require | node, node.require, require | node | node | |
Node.js CJS v20 | node | exports.require | node, node.require, require | node | node | |
Node.js CJS v21 | node | exports.require | node, node.require, require | node | node | |
Node.js ESM v14 | node | exports.node.import+exports.node.require | import, node, node.deno, node.import | node | node | |
Node.js ESM v16 | node | exports.node.import+exports.node.require | import, node, node.deno, node.import | node | node | |
Node.js ESM v18 | node | exports.node.import+exports.node.require | import, node, node.deno, node.import | node | node | |
Node.js ESM v20 | node | exports.node.import+exports.node.require | import, node, node.deno, node.import | node | node | |
Node.js ESM v21 | node | exports.node.import+exports.node.require | import, node, node.deno, node.import | node | node |