diff options
author | Yoshiya Hinosawa <stibium121@gmail.com> | 2023-02-17 23:58:52 +0900 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-17 23:58:52 +0900 |
commit | a01af067d79e78ea8e2c21cf0ef92d86d425f8eb (patch) | |
tree | b6345e86f04b61effd2be9b5dfd8c48507de7d65 /ext/node/polyfills | |
parent | 1a7666a6ca63b3dc6872d8f4631a2799af534159 (diff) |
test: add node compat tests (#17805)
Diffstat (limited to 'ext/node/polyfills')
-rw-r--r-- | ext/node/polyfills/internal/buffer.mjs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/node/polyfills/internal/buffer.mjs b/ext/node/polyfills/internal/buffer.mjs index 506f90507..1600462cf 100644 --- a/ext/node/polyfills/internal/buffer.mjs +++ b/ext/node/polyfills/internal/buffer.mjs @@ -20,6 +20,10 @@ import { normalizeEncoding } from "internal:deno_node/polyfills/internal/util.mj import { validateBuffer } from "internal:deno_node/polyfills/internal/validators.mjs"; import { isUint8Array } from "internal:deno_node/polyfills/internal/util/types.ts"; import { forgivingBase64Encode, forgivingBase64UrlEncode } from "internal:deno_web/00_infra.js"; +import { atob, btoa } from "internal:deno_web/05_base64.js"; +import { Blob } from "internal:deno_web/09_file.js"; + +export { atob, btoa, Blob }; const utf8Encoder = new TextEncoder(); @@ -1802,10 +1806,6 @@ function BufferBigIntNotDefined() { throw new Error("BigInt not supported"); } -export const atob = globalThis.atob; -export const Blob = globalThis.Blob; -export const btoa = globalThis.btoa; - export function readUInt48LE(buf, offset = 0) { validateNumber(offset, "offset"); const first = buf[offset]; |