lyxaira.glass 74ca844f42 Actualizacion cambios generados: seccion #12, #14 y #15. | il y a 4 ans | |
---|---|---|
.. | ||
test | il y a 4 ans | |
.npmignore | il y a 4 ans | |
.travis.yml | il y a 4 ans | |
LICENSE | il y a 4 ans | |
README.md | il y a 4 ans | |
index.js | il y a 4 ans | |
package.json | il y a 4 ans |
JSON functions that can convert buffers!
JSON mangles buffers by converting to an array… which isn’t helpful. json-buffers converts to base64 instead, and deconverts base64 to a buffer.
var JSONB = require('json-buffer')
var Buffer = require('buffer').Buffer
var str = JSONB.stringify(new Buffer('hello there!'))
console.log(JSONB.parse(str)) //GET a BUFFER back
MIT