Socket
Socket
Sign inDemoInstall

js-base64

Package Overview
Dependencies
0
Maintainers
1
Versions
68
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 3.1.1 to 3.1.2

base64-es5.js

6

base64.js

@@ -31,3 +31,3 @@

*/
const version = '3.1.1';
const version = '3.1.2';
const _b64chars

@@ -65,3 +65,3 @@ = 'ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/';

/**
* 100% compatibile with `window.btoa` of web browsers
* 100% compatible with `window.btoa` of web browsers
* @param {String} src binary string

@@ -124,3 +124,3 @@ * @returns {String} Base64-encoded string

/**
* 100% compatibile with `window.atob` of web browsers
* 100% compatible with `window.atob` of web browsers
* @param {String} src Base64-encoded string

@@ -127,0 +127,0 @@ * @returns {String} binary string

{
"name": "js-base64",
"version": "3.1.1",
"version": "3.1.2",
"description": "Yet another Base64 transcoder in pure-JS",
"main": "base64.js",
"module": "base64.mjs",
"directories": {
"test": "test"
},
"browser": "base64-es5.js",
"files": [
"base64.js",
"base64.mjs",
"base64-es5.js"
],
"scripts": {
"makecjs": "util/makecjs > base64.js",
"test": "npm run makecjs && mocha --require @babel/register",
"transpile": "babel base64.js -o base64-es5.js"
"transpile": "babel base64.js -o base64-es5.js",
"prepublishOnly": "npm run makecjs && npm run transpile"
},

@@ -22,6 +26,3 @@ "devDependencies": {

},
"repository": {
"type": "git",
"url": "git://github.com/dankogai/js-base64.git"
},
"repository": "git+https://github.com/dankogai/js-base64.git",
"keywords": [

@@ -28,0 +29,0 @@ "base64",

@@ -11,5 +11,6 @@ [![build status](https://secure.travis-ci.org/dankogai/js-base64.png)](http://travis-ci.org/dankogai/js-base64)

The hardest part of maintaing this module was not Base64 features, but cross-platform support (eg. nodejs vs web browsers). By making ES2015 mandatory virtually all codes are common (except `atob()` and `btoa()`).
The hardest part of maintaining this module was not Base64 features, but cross-platform support (eg. nodejs vs web browsers). By making ES2015 mandatory virtually all codes are common (except `atob()` and `btoa()`).
If you need to support legacy browsers like IE, use version 2 or transpile.
## Usage

@@ -48,3 +49,3 @@

```html
<script src="https://cdn.jsdelivr.net/npm/js-base64@3.1.1/base64.min.js">
<script src="https://cdn.jsdelivr.net/npm/js-base64@3.1.2/base64.min.js">
```

@@ -71,3 +72,3 @@

// note jsdelivr.net does not automatically minify .mjs
import { Base64 } from 'https://cdn.jsdelivr.net/npm/js-base64@3.1.1/base64.mjs';
import { Base64 } from 'https://cdn.jsdelivr.net/npm/js-base64@3.1.2/base64.mjs';
</script>

@@ -74,0 +75,0 @@ ```

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc