We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 98f9344 commit a618d14Copy full SHA for a618d14
src/index.ts
@@ -1,7 +1,7 @@
1
const chars = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';
2
3
// Use a lookup table to find the index.
4
-const lookup = new Uint8Array(256);
+const lookup = typeof Uint8Array === 'undefined' ? [] : new Uint8Array(256);
5
for (let i = 0; i < chars.length; i++) {
6
lookup[chars.charCodeAt(i)] = i;
7
}
0 commit comments