package.json 4.0 KB
{
  "_args": [
    [
      {
        "raw": "uws@~0.14.4",
        "scope": null,
        "escapedName": "uws",
        "name": "uws",
        "rawSpec": "~0.14.4",
        "spec": ">=0.14.4 <0.15.0",
        "type": "range"
      },
      "/Users/fzy/project/koa2_Sequelize_project/node_modules/engine.io"
    ]
  ],
  "_from": "uws@>=0.14.4 <0.15.0",
  "_id": "uws@0.14.5",
  "_inCache": true,
  "_location": "/uws",
  "_nodeVersion": "5.11.0",
  "_npmOperationalInternal": {
    "host": "packages-18-east.internal.npmjs.com",
    "tmp": "tmp/uws-0.14.5.tgz_1493399064525_0.939868062036112"
  },
  "_npmUser": {
    "name": "alexhultman",
    "email": "alexhultman@gmail.com"
  },
  "_npmVersion": "3.8.6",
  "_phantomChildren": {},
  "_requested": {
    "raw": "uws@~0.14.4",
    "scope": null,
    "escapedName": "uws",
    "name": "uws",
    "rawSpec": "~0.14.4",
    "spec": ">=0.14.4 <0.15.0",
    "type": "range"
  },
  "_requiredBy": [
    "/engine.io"
  ],
  "_resolved": "https://registry.npmjs.org/uws/-/uws-0.14.5.tgz",
  "_shasum": "67aaf33c46b2a587a5f6666d00f7691328f149dc",
  "_shrinkwrap": null,
  "_spec": "uws@~0.14.4",
  "_where": "/Users/fzy/project/koa2_Sequelize_project/node_modules/engine.io",
  "author": {
    "name": "Alex Hultman",
    "email": "alexhultman@gmail.com",
    "url": "https://github.com/alexhultman"
  },
  "bugs": {
    "url": "https://github.com/uWebSockets/uWebSockets/issues"
  },
  "dependencies": {},
  "description": "Tiny WebSockets",
  "devDependencies": {},
  "directories": {},
  "dist": {
    "shasum": "67aaf33c46b2a587a5f6666d00f7691328f149dc",
    "tarball": "https://registry.npmjs.org/uws/-/uws-0.14.5.tgz"
  },
  "engines": {
    "node": ">=4"
  },
  "homepage": "https://github.com/uWebSockets/uWebSockets",
  "keywords": [
    "tiny",
    "websockets"
  ],
  "license": "Zlib",
  "main": "uws.js",
  "maintainers": [
    {
      "name": "alexhultman",
      "email": "alexhultman@gmail.com"
    }
  ],
  "name": "uws",
  "optionalDependencies": {},
  "readme": "## Usage\n`uws` tries to mimic `ws` as closely as possible without sacrificing too much performance. In most cases you simply swap `require('ws')` with `require('uws')`:\n\n```javascript\nvar WebSocketServer = require('uws').Server;\nvar wss = new WebSocketServer({ port: 3000 });\n\nfunction onMessage(message) {\n    console.log('received: ' + message);\n}\n\nwss.on('connection', function(ws) {\n    ws.on('message', onMessage);\n    ws.send('something');\n});\n```\n\n##### Deviations from ws\nThere are some important incompatibilities with `ws` though, we aim to be ~90% compatible but will never implement behavior that is deemed too inefficient:\n\n* Binary data is passed zero-copy as an `ArrayBuffer`. This means you need to copy it to keep it past the callback. It also means you need to convert it with `Buffer.from(message)` if you expect a `Node.js Buffer`.\n* `webSocket._socket` is not a `net.Socket`, it is just a getter function with very basic functionalities.\n* `webSocket._socket.remote...` might fail, you need to cache it at connection.\n* `webSocket` acts like an `EventEmitter` with one listener per event maximum.\n* `webSocket.upgradeReq` is only valid during execution of the connection handler. If you want to keep properties of the upgradeReq for the entire lifetime of the webSocket you better attach that specific property to the webSocket at connection.\n\n## Installation\n[![](https://nodei.co/npm/uws.png)](https://www.npmjs.com/package/uws)\n\nAt installation `uws` will try to recompile itself using the system's C++11 compiler (GCC 4.8+, Clang 3.3, VC++ 2015+).\nIf this fails it will silently fall back to using the precompiled binaries.\nNPM installation will never fail but `require('uws')` will throw if it cannot properly load the binary module.\n",
  "readmeFilename": "README.md",
  "repository": {
    "type": "git",
    "url": "git+https://github.com/uWebSockets/uWebSockets.git"
  },
  "scripts": {
    "install": "node-gyp rebuild > build_log.txt 2>&1 || exit 0"
  },
  "version": "0.14.5"
}