nodejs-base64-encode

1.1.0 • Public • Published

Simple Node Js Package For Encode Decode a Given String

NPM

Installation

$ npm install nodejs-base64-encode

Examples

For Encode a String

const encode = require('nodejs-base64-encode');

console.log(encode.encode('npm world', 'base64'));

prints: bnBtIHdvcmxk

For Decode a String

const encode = require('nodejs-base64-encode');

console.log(encode.decode('bnBtIHdvcmxk', 'base64'));

prints: npm world

The possible encoding types are

  • ascii
  • utf8
  • ucs2
  • base64
  • binary
  • hex
  • utf8

This Package Is Under The MIT License

Package Sidebar

Install

npm i nodejs-base64-encode

Weekly Downloads

2,148

Version

1.1.0

License

MIT

Unpacked Size

3.47 kB

Total Files

5

Last publish

Collaborators

  • praveencrony