{"_id":"thread-it","_rev":"4159057","name":"thread-it","description":"wrap any sync module to thread worker","dist-tags":{"latest":"3.0.0"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"time":{"modified":"2026-03-01T20:33:58.000Z","created":"2019-08-16T11:09:06.660Z","3.0.0":"2025-04-24T14:19:18.440Z","2.0.0":"2022-06-11T21:01:32.911Z","1.1.3":"2020-02-25T11:16:26.114Z","1.1.2":"2019-08-23T12:16:39.875Z","1.1.1":"2019-08-23T11:17:21.764Z","1.1.0":"2019-08-16T15:18:45.440Z","1.0.3":"2019-08-16T11:31:07.972Z","1.0.2":"2019-08-16T11:28:02.810Z","1.0.1":"2019-08-16T11:10:55.901Z","1.0.0":"2019-08-16T11:09:06.660Z"},"users":{},"author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"repository":{"type":"git","url":"git+https://github.com/coderaiser/node-thread-it.git"},"versions":{"3.0.0":{"name":"thread-it","version":"3.0.0","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git+https://github.com/coderaiser/node-thread-it.git"},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/wait":"^2.1.0","try-catch":"^3.0.1","try-to-catch":"^3.0.0"},"license":"MIT","devDependencies":{"c8":"^10.1.3","coveralls":"^3.0.2","eslint":"^9.25.1","eslint-plugin-n":"^17.17.0","eslint-plugin-node":"^11.0.0","eslint-plugin-putout":"^26.1.0","madrun":"^11.0.1","mock-require":"^3.0.3","nodemon":"^3.1.10","putout":"^40.0.12","supertape":"^11.1.0"},"engines":{"node":">=16"},"publishConfig":{"access":"public"},"_id":"thread-it@3.0.0","gitHead":"17a964a3fe10b6472403da5d97d39d48ed1a9e11","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_nodeVersion":"22.14.0","_npmVersion":"11.1.0","dist":{"shasum":"362917d67165b7d0b20202b3e92774ab9ff99f10","size":4019,"noattachment":false,"key":"/thread-it/-/thread-it-3.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-3.0.0.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/thread-it_3.0.0_1745504358264_0.7599800472471512"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2025-04-24T14:19:18.440Z","publish_time":1745504358440,"_source_registry_name":"default","_cnpm_publish_time":1745504358440},"2.0.0":{"name":"thread-it","version":"2.0.0","type":"commonjs","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","commitType":"colon","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/coderaiser/node-thread-it.git"},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/wait":"^2.1.0","try-catch":"^3.0.1","try-to-catch":"^3.0.0"},"license":"MIT","devDependencies":{"c8":"^7.11.3","coveralls":"^3.0.2","eslint":"^8.17.0","eslint-plugin-node":"^11.0.0","eslint-plugin-putout":"^15.6.0","madrun":"^9.0.4","mock-require":"^3.0.3","nodemon":"^2.0.2","putout":"^26.14.0","supertape":"^7.4.1"},"engines":{"node":">=16"},"publishConfig":{"access":"public"},"gitHead":"77ccec211bed733b3878399b9ead377b63915476","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_id":"thread-it@2.0.0","_nodeVersion":"18.3.0","_npmVersion":"8.3.0","dist":{"shasum":"84367064da443ebcae65cbd949f77a322997853c","size":3854,"noattachment":false,"key":"/thread-it/-/thread-it-2.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-2.0.0.tgz"},"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_2.0.0_1654981292775_0.8993190689961683"},"_hasShrinkwrap":false,"_cnpmcore_publish_time":"2022-06-11T21:01:43.439Z","publish_time":1654981292911,"_cnpm_publish_time":1654981292911},"1.1.3":{"name":"thread-it","version":"1.1.3","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/coderaiser/node-thread-it.git"},"nyc":{"exclude":["madrun.js","test"]},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^3.0.0"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^11.0.0","eslint-plugin-putout":"^3.2.1","madrun":"^5.4.4","mock-require":"^3.0.3","nodemon":"^2.0.2","nyc":"^15.0.0","putout":"^7.13.4","supertape":"^1.2.3","try-to-catch":"^3.0.0"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"6ecef91d6cb27082d34de02b8cf51a8c3030b389","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_id":"thread-it@1.1.3","_nodeVersion":"13.9.0","_npmVersion":"6.12.1","dist":{"shasum":"74fa99dc8be302158aa65549372b61f2affdd5ec","size":3748,"noattachment":false,"key":"/thread-it/-/thread-it-1.1.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.1.3.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.1.3_1582629386008_0.36705579390759735"},"_hasShrinkwrap":false,"publish_time":1582629386114,"_cnpm_publish_time":1582629386114,"_cnpmcore_publish_time":"2021-12-16T22:42:58.671Z"},"1.1.2":{"name":"thread-it","version":"1.1.2","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/coderaiser/node-thread-it.git"},"nyc":{"exclude":["madrun.js","test"]},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^2.0.0"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^9.1.0","madrun":"^2.5.0","mock-require":"^3.0.3","nodemon":"^1.11.0","nyc":"^14.1.1","putout":"^5.5.0","redrun":"^7.0.0","supertape":"^1.2.3","try-to-catch":"^1.1.1"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"54b48cfa595fb39e810ace5a28d897e8d3e1c55f","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_id":"thread-it@1.1.2","_nodeVersion":"12.9.0","_npmVersion":"6.10.0","dist":{"shasum":"176c5fd0753c75d5b89edabc9f51c5cf7d39c5ac","size":3669,"noattachment":false,"key":"/thread-it/-/thread-it-1.1.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.1.2.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.1.2_1566562599691_0.3147019946017924"},"_hasShrinkwrap":false,"publish_time":1566562599875,"_cnpm_publish_time":1566562599875,"_cnpmcore_publish_time":"2021-12-16T22:42:58.857Z"},"1.1.1":{"name":"thread-it","version":"1.1.1","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/coderaiser/node-thread-it.git"},"nyc":{"exclude":["madrun.js","test"]},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^2.0.0"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^9.1.0","madrun":"^2.5.0","mock-require":"^3.0.3","nodemon":"^1.11.0","nyc":"^14.1.1","putout":"^5.5.0","redrun":"^7.0.0","supertape":"^1.2.3","try-to-catch":"^1.1.1"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"b049e89b6f635a02784bf40fe04fa1746d7b2174","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_id":"thread-it@1.1.1","_nodeVersion":"12.9.0","_npmVersion":"6.10.0","dist":{"shasum":"b4c3a03fa451009b7c37b582e78b60894edd4b1c","size":3611,"noattachment":false,"key":"/thread-it/-/thread-it-1.1.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.1.1.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.1.1_1566559041672_0.9874576965244284"},"_hasShrinkwrap":false,"publish_time":1566559041764,"_cnpm_publish_time":1566559041764,"_cnpmcore_publish_time":"2021-12-16T22:42:59.088Z"},"1.1.0":{"name":"thread-it","version":"1.1.0","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/coderaiser/node-thread-it.git"},"nyc":{"exclude":["madrun.js","test"]},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^2.0.0"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^9.1.0","madrun":"^2.5.0","mock-require":"^3.0.3","nodemon":"^1.11.0","nyc":"^14.1.1","putout":"^5.5.0","redrun":"^7.0.0","supertape":"^1.2.3","try-to-catch":"^1.1.1"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"112700a340ef818473af7f8a1424ab1a53dbc106","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_id":"thread-it@1.1.0","_nodeVersion":"12.8.1","_npmVersion":"6.10.0","dist":{"shasum":"022c45c3103d61ecffdcfaa976add7f3d4a7e580","size":3598,"noattachment":false,"key":"/thread-it/-/thread-it-1.1.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.1.0.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.1.0_1565968725292_0.7954318965114151"},"_hasShrinkwrap":false,"publish_time":1565968725440,"_cnpm_publish_time":1565968725440,"_cnpmcore_publish_time":"2021-12-16T22:42:59.302Z"},"1.0.3":{"name":"thread-it","version":"1.0.3","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/coderaiser/node-thread-it.git"},"nyc":{"exclude":["madrun.js","test"]},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^2.0.0"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^9.1.0","madrun":"^2.5.0","mock-require":"^3.0.3","nodemon":"^1.11.0","nyc":"^14.1.1","putout":"^5.5.0","redrun":"^7.0.0","supertape":"^1.2.3","try-to-catch":"^1.1.1"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"a2e78c6f3f3aea1359fb601436b76aeca53a035f","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_id":"thread-it@1.0.3","_nodeVersion":"12.8.1","_npmVersion":"6.10.0","dist":{"shasum":"3a99e5ea0c70f709cf48aa0af5c0267672bfe45b","size":3446,"noattachment":false,"key":"/thread-it/-/thread-it-1.0.3.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.0.3.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.0.3_1565955067629_0.2929518079052116"},"_hasShrinkwrap":false,"publish_time":1565955067972,"_cnpm_publish_time":1565955067972,"_cnpmcore_publish_time":"2021-12-16T22:42:59.518Z"},"1.0.2":{"name":"thread-it","version":"1.0.2","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/coderaiser/node-thread-it.git"},"nyc":{"exclude":["madrun.js"]},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^2.0.0"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^9.1.0","madrun":"^2.5.0","mock-require":"^3.0.3","nodemon":"^1.11.0","nyc":"^14.1.1","putout":"^5.5.0","redrun":"^7.0.0","supertape":"^1.2.3","try-to-catch":"^1.1.1"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"38fe6523f6ef645b3eb8d4f43ffb847895e9a865","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"_id":"thread-it@1.0.2","_nodeVersion":"12.8.1","_npmVersion":"6.10.0","dist":{"shasum":"2b9a1ade7bf7f107480de37a847fa60a1a6b5198","size":3408,"noattachment":false,"key":"/thread-it/-/thread-it-1.0.2.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.0.2.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.0.2_1565954882698_0.33130327960853045"},"_hasShrinkwrap":false,"publish_time":1565954882810,"_cnpm_publish_time":1565954882810,"_cnpmcore_publish_time":"2021-12-16T22:42:59.750Z"},"1.0.1":{"name":"thread-it","version":"1.0.1","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to thread worker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/iocmd/thread-it.git"},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^2.0.0","try-to-catch":"^1.1.1"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^9.1.0","madrun":"^2.5.0","mock-require":"^3.0.3","nodemon":"^1.11.0","nyc":"^14.1.1","putout":"^5.5.0","redrun":"^7.0.0","supertape":"^1.2.3"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"5d6dd5331a97fa9e3e61e1aaef781369e41cf027","bugs":{"url":"https://github.com/iocmd/thread-it/issues"},"_id":"thread-it@1.0.1","_nodeVersion":"12.8.1","_npmVersion":"6.10.0","dist":{"shasum":"8aa15272a4fdb223dad7576503011f713ebb1416","size":3359,"noattachment":false,"key":"/thread-it/-/thread-it-1.0.1.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.0.1.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.0.1_1565953855781_0.17754502051428211"},"_hasShrinkwrap":false,"publish_time":1565953855901,"_cnpm_publish_time":1565953855901,"_cnpmcore_publish_time":"2021-12-16T22:42:59.982Z"},"1.0.0":{"name":"thread-it","version":"1.0.0","author":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com","url":"https://github.com/coderaiser"},"description":"wrap any sync module to webworker","homepage":"http://github.com/coderaiser/node-thread-it","main":"lib/thread-it.js","repository":{"type":"git","url":"git://github.com/iocmd/thread-it.git"},"keywords":["worker","threads","worker_threads","promise"],"scripts":{"test":"madrun test","coverage":"madrun coverage","lint":"madrun lint","fix:lint":"madrun fix:lint","report":"madrun report","watcher":"madrun watcher","watch:test":"madrun watch:test","watch:lint":"madrun watch:lint","watch:tape":"madrun watch:tape","watch:coverage:base":"madrun watch:coverage:base","watch:coverage:tape":"madrun watch:coverage:tape","watch:coverage":"madrun watch:coverage"},"dependencies":{"@iocmd/hold-up":"^1.1.0","try-catch":"^2.0.0","try-to-catch":"^1.1.1"},"license":"MIT","devDependencies":{"@cloudcmd/stub":"^2.3.1","coveralls":"^3.0.2","eslint":"^6.1.0","eslint-plugin-node":"^9.1.0","madrun":"^2.5.0","mock-require":"^3.0.3","nodemon":"^1.11.0","nyc":"^14.1.1","putout":"^5.5.0","redrun":"^7.0.0","supertape":"^1.2.3"},"engines":{"node":">=8.3"},"publishConfig":{"access":"public"},"gitHead":"3cf7662978882845499e3e3ba3e94e1044cc5be1","bugs":{"url":"https://github.com/iocmd/thread-it/issues"},"_id":"thread-it@1.0.0","_nodeVersion":"12.8.1","_npmVersion":"6.10.0","dist":{"shasum":"0547172e0c296f999b76e10bf6c8bf05e8531e45","size":3294,"noattachment":false,"key":"/thread-it/-/thread-it-1.0.0.tgz","tarball":"http://registry.cnpm.dingdandao.com/thread-it/download/thread-it-1.0.0.tgz"},"maintainers":[{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"}],"_npmUser":{"name":"coderaiser","email":"mnemonic.enemy@gmail.com"},"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/thread-it_1.0.0_1565953746498_0.16687422439160904"},"_hasShrinkwrap":false,"publish_time":1565953746660,"_cnpm_publish_time":1565953746660,"_cnpmcore_publish_time":"2021-12-16T22:43:00.194Z"}},"readme":"# Thread It [![License][LicenseIMGURL]][LicenseURL] [![NPM version][NPMIMGURL]][NPMURL] [![Build Status][BuildStatusIMGURL]][BuildStatusURL] [![Coverage Status][CoverageIMGURL]][CoverageURL]\n\nDrastically simplified [worker threads](https://nodejs.org/dist/latest-v12.x/docs/api/worker_threads.html), on node `v8` or `v10` without `--experimental-worker` just\nwraps your code with a promise so you don't have to warry about a thing, just use `thread it` and it will use `workers` where can.\n\nChoose any sync module from `npm` and instead of `require` use `threadIt`.\n\n*Caution: not all data types can be passed to Worker Thread, for example you just can't pass a function, read carefully [what types are supported](https://nodejs.org/dist/latest-v12.x/docs/api/worker_threads.html#worker_threads_port_postmessage_value_transferlist).*\n\n## Install\n\n`npm i thread-it`\n\n## API\n\n### threadIt(name[, options])\n\nUnder the hood `threadId` uses [holdUp](https://github.com/coderaiser/hold-up) so you can use the same options to find a free worker from queue.\n\n- `name` - string\n- `options` - options may contain:\n  - `log`\n  - `count`\n  - `time`\n\nAlso you can set `THREAD_IT_COUNT` env variable to workers count, if `0` it means disabled worker threads.\n\n```js\nconst threadIt = require('thread-it');\n\n// init workers, depend on os.cpus()\nthreadIt.init();\n\nconst putout = threadIt('putout');\nconst result = await putout(`const t = 'hello'`);\n\n// when you need to override options use\nthreadIt('putout', {\n    count: 5, // default\n    time: 1000, // default\n    log: () => {}, // default\n});\n\n// terminate workers when no need anymore\nthreadIt.terminate();\n```\n\n## Related\n\n- [hold-up](https://github.com/iocmd/hold-up \"Hold Up\") - setInterval with promises, counter and error handling\n- [currify](https://github.com/coderaiser/currify \"currify\") - translate the evaluation of a function that takes multiple arguments into evaluating a sequence of functions, each with a single or more arguments.\n- [fullstore](https://github.com/coderaiser/fullstore \"fullstore\") - functional variables.\n- [wraptile](https://github.com/coderaiser/wraptile \"wraptile\") - translate the evaluation of a function that takes multiple arguments into evaluating a sequence of 2 functions, each with a any count of arguments.\n\n## License\n\nMIT\n\n[NPMIMGURL]: https://img.shields.io/npm/v/thread-it.svg?style=flat\n[BuildStatusIMGURL]: https://travis-ci.com/coderaiser/node-thread-it.svg?branch=master\n[LicenseIMGURL]: https://img.shields.io/badge/license-MIT-317BF9.svg?style=flat\n[NPMURL]: https://npmjs.org/package/thread-it \"npm\"\n[BuildStatusURL]: https://travis-ci.com/coderaiser/node-thread-it \"Build Status\"\n[LicenseURL]: https://tldrlegal.com/license/mit-license \"MIT License\"\n[CoverageURL]: https://coveralls.io/github/coderaiser/node-thread-it?branch=master\n[CoverageIMGURL]: https://coveralls.io/repos/coderaiser/node-thread-it/badge.svg?branch=master&service=github\n","_attachments":{},"homepage":"http://github.com/coderaiser/node-thread-it","bugs":{"url":"https://github.com/coderaiser/node-thread-it/issues"},"license":"MIT"}