convert-string
Convert to/from strings and array of bytes
Last updated 11 years ago by jp .
Repository · Bugs · Original npm · Tarball · package.json
$ npm install convert-string 
SYNC missed versions from official npm registry.

convert-string

JavaScript component to convert to/from strings and byte arrays.

AMD/CommonJS compatible.

Install

Node.js/Browserify

npm install --save convert-string

Component

component install cryptocoin/convert-string

Bower

bower install convert-string

Script

<script src="/path/to/convert-string.js"></script>

Usage

stringToBytes(str)

bytesToString(bytes)

UTF8.stringToBytes(str)

UTF8.bytesToString(bytes)

Credits

Loosely inspired by code from here: https://github.com/vbuterin/bitcoinjs-lib & CryptoJS

References on JavaScript UTF-8 forced encoding

(these sources are also included as PDFs in the repo in case the links go dead)

License

(MIT License)

Copyright 2013, JP Richardson jprichardson@gmail.com

Current Tags

  • 0.1.0                                ...           latest (11 years ago)

1 Versions

  • 0.1.0                                ...           11 years ago
Maintainers (1)
Downloads
Total 0
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 0
Dependencies (0)
None
Dev Dependencies (3)
Dependents (1)

© 2010 - cnpmjs.org x YWFE | Home | YWFE