Comparing version
@@ -12,7 +12,7 @@ /** | ||
*/ | ||
declare const version = "3.7.6"; | ||
declare const version = "3.7.7"; | ||
/** | ||
* @deprecated use lowercase `version`. | ||
*/ | ||
declare const VERSION = "3.7.6"; | ||
declare const VERSION = "3.7.7"; | ||
/** | ||
@@ -19,0 +19,0 @@ * polyfill version of `btoa` |
@@ -40,3 +40,3 @@ // | ||
*/ | ||
var version = '3.7.6'; | ||
var version = '3.7.7'; | ||
/** | ||
@@ -46,4 +46,2 @@ * @deprecated use lowercase `version`. | ||
var VERSION = version; | ||
var _hasatob = typeof atob === 'function'; | ||
var _hasbtoa = typeof btoa === 'function'; | ||
var _hasBuffer = typeof Buffer === 'function'; | ||
@@ -92,3 +90,3 @@ var _TD = typeof TextDecoder === 'function' ? new TextDecoder() : undefined; | ||
*/ | ||
var _btoa = _hasbtoa ? function (bin) { return btoa(bin); } | ||
var _btoa = typeof btoa === 'function' ? function (bin) { return btoa(bin); } | ||
: _hasBuffer ? function (bin) { return Buffer.from(bin, 'binary').toString('base64'); } | ||
@@ -222,3 +220,3 @@ : btoaPolyfill; | ||
*/ | ||
var _atob = _hasatob ? function (asc) { return atob(_tidyB64(asc)); } | ||
var _atob = typeof atob === 'function' ? function (asc) { return atob(_tidyB64(asc)); } | ||
: _hasBuffer ? function (asc) { return Buffer.from(asc, 'base64').toString('binary'); } | ||
@@ -225,0 +223,0 @@ : atobPolyfill; |
{ | ||
"name": "js-base64", | ||
"version": "3.7.6", | ||
"version": "3.7.7", | ||
"description": "Yet another Base64 transcoder in pure-JS", | ||
@@ -5,0 +5,0 @@ "main": "base64.js", |
@@ -28,3 +28,3 @@ [](https://github.com/dankogai/js-base64/actions/workflows/node.js.yml) | ||
```html | ||
<script src="https://cdn.jsdelivr.net/npm/js-base64@3.7.6/base64.min.js"></script> | ||
<script src="https://cdn.jsdelivr.net/npm/js-base64@3.7.7/base64.min.js"></script> | ||
``` | ||
@@ -52,3 +52,3 @@ | ||
// note jsdelivr.net does not automatically minify .mjs | ||
import { Base64 } from 'https://cdn.jsdelivr.net/npm/js-base64@3.7.6/base64.mjs'; | ||
import { Base64 } from 'https://cdn.jsdelivr.net/npm/js-base64@3.7.7/base64.mjs'; | ||
</script> | ||
@@ -60,3 +60,3 @@ ``` | ||
// or if you prefer no Base64 namespace | ||
import { encode, decode } from 'https://cdn.jsdelivr.net/npm/js-base64@3.7.6/base64.mjs'; | ||
import { encode, decode } from 'https://cdn.jsdelivr.net/npm/js-base64@3.7.7/base64.mjs'; | ||
</script> | ||
@@ -63,0 +63,0 @@ ``` |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
38601
-0.29%743
-0.54%