Skip to content

use WebWorkers to parse/stringify/compress/decompress JSON. Realeased for private usage in 2014

License

Notifications You must be signed in to change notification settings

pashoo2/JSONWorkers

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

JSONWorkers

 

With webpack-like just use* import * from “JSONWorkers”*.

With native code use import * from “./node_modules/JSONWorker/index.js” or <script src=“./node_modules/JSONWorker/index.js”>

!Does not work with nodejs

 

Set the following global JSON API methods:

JSON.parseAsync(JSON.parseSync) (str, callback, context, flCompression) parse a given string async/sync with/without a zlib compression

  • str{string} string to parse

    • callback {Function} when parsed callback({object|[]|string|Error}

    • context {object} this context will applied for callback. callback.call(context, result)

    • flCompression {boolean} if true, then decompress a string compressed with pakolibrary or

JSON.stringifyAsync(JSON.stringifySync) (obj, callback, context, flCompression) - stringify a given object async/sync with/without a zlib compression

  • obj {object|[]|string} object/array/string to stringify and/or compress with zlib

    • callback {Function} when all done callback({string|Error}

    • context {object} this context will applied for callback. callback.call(context, result)

    • flCompression {boolean} if true, then compress the resulted string

About

use WebWorkers to parse/stringify/compress/decompress JSON. Realeased for private usage in 2014

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published