{ "_args": [ [ { "raw": "pend@~1.2.0", "scope": null, "escapedName": "pend", "name": "pend", "rawSpec": "~1.2.0", "spec": ">=1.2.0 <1.3.0", "type": "range" }, "/Users/fzy/project/koa2_Sequelize_project/node_modules/fd-slicer" ] ], "_from": "pend@>=1.2.0 <1.3.0", "_id": "pend@1.2.0", "_inCache": true, "_location": "/pend", "_npmUser": { "name": "superjoe", "email": "superjoe30@gmail.com" }, "_npmVersion": "1.4.21", "_phantomChildren": {}, "_requested": { "raw": "pend@~1.2.0", "scope": null, "escapedName": "pend", "name": "pend", "rawSpec": "~1.2.0", "spec": ">=1.2.0 <1.3.0", "type": "range" }, "_requiredBy": [ "/fd-slicer" ], "_resolved": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz", "_shasum": "7a57eb550a6783f9115331fcf4663d5c8e007a50", "_shrinkwrap": null, "_spec": "pend@~1.2.0", "_where": "/Users/fzy/project/koa2_Sequelize_project/node_modules/fd-slicer", "author": { "name": "Andrew Kelley", "email": "superjoe30@gmail.com" }, "bugs": { "url": "https://github.com/andrewrk/node-pend/issues" }, "dependencies": {}, "description": "dead-simple optimistic async helper", "devDependencies": {}, "directories": {}, "dist": { "shasum": "7a57eb550a6783f9115331fcf4663d5c8e007a50", "tarball": "https://registry.npmjs.org/pend/-/pend-1.2.0.tgz" }, "gitHead": "ed57bbe8520518dca24d0c6bb847ffb6b68ae6f9", "homepage": "https://github.com/andrewrk/node-pend#readme", "license": "MIT", "main": "index.js", "maintainers": [ { "name": "superjoe", "email": "superjoe30@gmail.com" } ], "name": "pend", "optionalDependencies": {}, "readme": "# Pend\n\nDead-simple optimistic async helper.\n\n## Usage\n\n```js\nvar Pend = require('pend');\nvar pend = new Pend();\npend.max = 10; // defaults to Infinity\nsetTimeout(pend.hold(), 1000); // pend.wait will have to wait for this hold to finish\npend.go(function(cb) {\n console.log(\"this function is immediately executed\");\n setTimeout(function() {\n console.log(\"calling cb 1\");\n cb();\n }, 500);\n});\npend.go(function(cb) {\n console.log(\"this function is also immediately executed\");\n setTimeout(function() {\n console.log(\"calling cb 2\");\n cb();\n }, 1000);\n});\npend.wait(function(err) {\n console.log(\"this is excuted when the first 2 have returned.\");\n console.log(\"err is a possible error in the standard callback style.\");\n});\n```\n\nOutput:\n\n```\nthis function is immediately executed\nthis function is also immediately executed\ncalling cb 1\ncalling cb 2\nthis is excuted when the first 2 have returned.\nerr is a possible error in the standard callback style.\n```\n", "readmeFilename": "README.md", "repository": { "type": "git", "url": "git://github.com/andrewrk/node-pend.git" }, "scripts": { "test": "node test.js" }, "version": "1.2.0" }