{"_id":"@8n/srv","name":"@8n/srv","dist-tags":{"latest":"0.0.1"},"versions":{"0.0.1":{"name":"@8n/srv","version":"0.0.1","repository":{"type":"git","url":"git+https://github.com/i18n-site/node.git"},"homepage":"https://github.com/i18n-site/node/tree/main/srv","author":{"name":"i18n.site@gmail.com"},"license":"BSL1.1","exports":{".":"./lib/index.js","./*":"./lib/*"},"devDependencies":{},"scripts":{},"type":"module","trustedDependencies":["uWebSockets"],"dependencies":{"@w5/msgpack":"^0.0.2","tough-cookie":"^4.1.3","uWebSockets":"github:uNetworking/uWebSockets.js#v20.32.0"},"_id":"@8n/srv@0.0.1","gitHead":"a741e65b4b2d3e39ccdad2f7ff0074ca37133fb4","description":"[‼️]: ✏️README.mdt","bugs":{"url":"https://github.com/i18n-site/node/issues"},"_nodeVersion":"20.7.0","_npmVersion":"10.1.0","dist":{"integrity":"sha512-Wqp7V8eZWu9Iim3TzFTM3YXYw0YZfERgD4p29Huzv7ABclnwgnnUwZ6cvb2bHlWraXXdMfZx1j50Jog67iHLgw==","shasum":"6d4fa3fd92545950935c9199315a89fa62a57e0b","tarball":"https://registry.npmjs.org/@8n/srv/-/srv-0.0.1.tgz","fileCount":7,"unpackedSize":6548,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEYCIQDLiyFqYDkvYYYFd23FK917FqBZLTtGCB50PSSXXT12nAIhAIOi48YD5BoMnZsM9ONJObd8ImlCf+emCH/okNHdtCNS"}]},"_npmUser":{"name":"i18n-now","email":"i18n.site@gmail.com"},"directories":{},"maintainers":[{"name":"i18n-now","email":"i18n.site@gmail.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/srv_0.0.1_1696060175301_0.6261045530789768"},"_hasShrinkwrap":false}},"time":{"created":"2023-09-30T07:49:35.187Z","0.0.1":"2023-09-30T07:49:35.551Z","modified":"2023-09-30T07:49:35.872Z"},"maintainers":[{"name":"i18n-now","email":"i18n.site@gmail.com"}],"description":"[‼️]: ✏️README.mdt","homepage":"https://github.com/i18n-site/node/tree/main/srv","repository":{"type":"git","url":"git+https://github.com/i18n-site/node.git"},"author":{"name":"i18n.site@gmail.com"},"bugs":{"url":"https://github.com/i18n-site/node/issues"},"license":"BSL1.1","readme":"[‼️]: ✏️README.mdt\n\n# @8n/srv\n\n返回值\n\n    如果函数，会被传入 res ，可以 res.writeStatus(status).end(r)\n\n    如果不是 undefined ，会被 msgpack pack\n\npost,put\n\n如果 content_type.endsWith '/json'\n\n    body 如果 length > 1\n\n    会被 json parse\n\n    如果是一个数组 会 f.apply opt, body\n\n    否则会 f.call opt, body\n\n否则如果 body 有的长度 f.call opt, body\n\n[test/main.coffee](./test/main.coffee) :\n\n```coffee\n#!/usr/bin/env coffee\n```\n\noutput :\n\n```\n/test\n→ http://127.0.0.1:3223\nuWS.App {}\npost test\npost test\npost test\npost test\n```\n","readmeFilename":"README.md"}