check-base-encoding
npm module to check and verify base encoding of a particular string. Specifications for base64, base64url, base32, base32hex, and hex encodings have been taken from RFC 4648.
Installation
npm install --save check-base-encoding
Or on the client side,
Usage
var checkBase = ; // Following examples yield true as the outputconsole; console; console; console; console; console; // If your string is not padded (in the case of first four functions),// you need to pass a second argument `true` which enforces no padding // Following is the example of a VAPID keyconsole;// --> true