{"name":"simple-swizzle","description":"Simply swizzle your arguments","version":"0.2.4","author":{"name":"Qix","url":"http://github.com/qix-"},"keywords":["argument","arguments","swizzle","swizzling","parameter","parameters","mixed","array"],"license":"MIT","scripts":{"pretest":"xo","test":"mocha --compilers coffee:coffee-script/register"},"repository":{"type":"git","url":"git+https://github.com/qix-/node-simple-swizzle.git"},"devDependencies":{"coffee-script":"^1.9.3","coveralls":"^2.11.2","istanbul":"^0.3.17","mocha":"^2.2.5","should":"^7.0.1","xo":"^0.7.1"},"dependencies":{"is-arrayish":"^0.3.1"},"_id":"simple-swizzle@0.2.4","gitHead":"eb4f9b11182126927dcdc90149a41126c4b846c2","bugs":{"url":"https://github.com/qix-/node-simple-swizzle/issues"},"homepage":"https://github.com/qix-/node-simple-swizzle#readme","_nodeVersion":"22.15.0","_npmVersion":"10.9.2","dist":{"integrity":"sha512-nAu1WFPQSMNr2Zn9PGSZK9AGn4t/y97lEm+MXTtUDwfP0ksAIX4nO+6ruD9Jwut4C49SB1Ws+fbXsm/yScWOHw==","shasum":"a8d11a45a11600d6a1ecdff6363329e3648c3667","tarball":"http://registry-npm.ywwl.com/simple-swizzle/download/simple-swizzle-0.2.4.tgz","fileCount":4,"unpackedSize":4091,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIAa8rUxobcinhs080KirYVHQkqRoF79SKl3LmgMsvIsZAiEA8G2neI5S8jg8VPxz+h9HoRr7yoA/sYGWjvtjcaRUuM8="}],"size":2219,"noattachment":false,"key":"/simple-swizzle/-/simple-swizzle-0.2.4.tgz"},"_npmUser":{"name":"qix","email":"npm@josh.junon.me"},"directories":{},"maintainers":[{"name":"qix","email":"npm@josh.junon.me"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/simple-swizzle_0.2.4_1757780360883_0.6346575433013992"},"_hasShrinkwrap":false,"readme":"> **NOTE:** ⚠️ **Don't use this package in new projects.** It is a **huge anti-pattern** and will only confuse and annoy people who use whatever code you write with it. I wrote this in a time when Javascript and Node.js were still pretty experimental and clever things like this weren't frowned upon. I've also learned a LOT about proper API design since I wrote this package. DO. NOT. USE. THIS. PACKAGE. If you're reaching for it, please *really* reconsider your API's design.\n\n---\n\n# simple-swizzle [![Travis-CI.org Build Status](https://img.shields.io/travis/Qix-/node-simple-swizzle.svg?style=flat-square)](https://travis-ci.org/Qix-/node-simple-swizzle) [![Coveralls.io Coverage Rating](https://img.shields.io/coveralls/Qix-/node-simple-swizzle.svg?style=flat-square)](https://coveralls.io/r/Qix-/node-simple-swizzle)\n\n> [Swizzle](https://en.wikipedia.org/wiki/Swizzling_(computer_graphics)) your function arguments; pass in mixed arrays/values and get a clean array\n\n## Usage\n\n```js\nvar swizzle = require('simple-swizzle');\n\nfunction myFunc() {\n\tvar args = swizzle(arguments);\n\t// ...\n\treturn args;\n}\n\nmyFunc(1, [2, 3], 4); // [1, 2, 3, 4]\nmyFunc(1, 2, 3, 4);   // [1, 2, 3, 4]\nmyFunc([1, 2, 3, 4]); // [1, 2, 3, 4]\n```\n\nFunctions can also be wrapped to automatically swizzle arguments and be passed\nthe resulting array.\n\n```js\nvar swizzle = require('simple-swizzle');\n\nvar swizzledFn = swizzle.wrap(function (args) {\n\t// ...\n\treturn args;\n});\n\nswizzledFn(1, [2, 3], 4); // [1, 2, 3, 4]\nswizzledFn(1, 2, 3, 4);   // [1, 2, 3, 4]\nswizzledFn([1, 2, 3, 4]); // [1, 2, 3, 4]\n```\n\n## License\nLicensed under the [MIT License](http://opensource.org/licenses/MIT).\nYou can find a copy of it in [LICENSE](LICENSE).\n","publish_time":1757780361071,"_cnpm_publish_time":1757780361071,"dist-tags":{"latest":"0.2.4"}}