xhidebinder
v1.0.0
Published
A data code by both 0x00 and 0x20
Downloads
6
Readme
~~这是一种神奇的编码~~
This is a funny code
XhideBinder Code
将数据编码成由 0x00 和 0x20 两个字符串组成的字符串/Buffer/blob Make data to string/buf/array by both 0x00 and 0x20 本库采用LiveScript编写(支持es5) Module write by LiveScript 支持浏览器&Nodejs Supports browsers and Nodejs
Method 方法
编码并写入文件 Encode & write to file
const { xb } = require( "XhideBinder" ),
{ writeFileSync } = require( "fs" )
writeFileSync( "test.txt", xb.encode( "hello,world" ) )
解码文件 Decode from file
const { xb } = require( "XhideBinder" ),
{ readFileSync } = require( "fs" )
console.log(
xb.decode( readFileSync( "test.txt" ) )
)
编码成数组 Encode to array
const { xb } = require( "XhideBinder" ),
{ writeFileSync } = require( "fs" )
console.log( xb.encode( "hello,world", true ) )