Ignore:
Timestamp:
11/25/21 22:08:24 (3 years ago)
Author:
Ema <ema_spirova@…>
Branches:
master
Children:
8d391a1
Parents:
59329aa
Message:

primeNG components

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trip-planner-front/node_modules/engine.io/README.md

    r59329aa re29cc2e  
    22# Engine.IO: the realtime engine
    33
    4 [![Build Status](https://github.com/socketio/engine.io/workflows/CI/badge.svg?branch=master))](https://github.com/socketio/engine.io/actions)
     4[![Build Status](https://github.com/socketio/engine.io/workflows/CI/badge.svg?branch=master)](https://github.com/socketio/engine.io/actions)
    55[![NPM version](https://badge.fury.io/js/engine.io.svg)](http://badge.fury.io/js/engine.io)
    66
     
    189189const httpServer = require('http').createServer().listen(3000);
    190190const server = engine.attach(httpServer, {
    191   wsEngine: 'uws' // requires having uws as dependency
     191  wsEngine: require('eiows').Server // requires having eiows as dependency
    192192});
    193193
     
    205205    - **Arguments**
    206206      - `Socket`: a Socket object
     207
     208- `initial_headers`
     209    - Fired on the first request of the connection, before writing the response headers
     210    - **Arguments**
     211      - `headers` (`Object`): a hash of headers
     212      - `req` (`http.IncomingMessage`): the request
     213
     214- `headers`
     215    - Fired on the all requests of the connection, before writing the response headers
     216    - **Arguments**
     217      - `headers` (`Object`): a hash of headers
     218      - `req` (`http.IncomingMessage`): the request
     219
     220- `connection_error`
     221    - Fired when an error occurs when establishing the connection.
     222    - **Arguments**
     223      - `error`: an object with following properties:
     224        - `req` (`http.IncomingMessage`): the request that was dropped
     225        - `code` (`Number`): one of `Server.errors`
     226        - `message` (`string`): one of `Server.errorMessages`
     227        - `context` (`Object`): extra info about the error
     228
     229| Code | Message |
     230| ---- | ------- |
     231| 0 | "Transport unknown"
     232| 1 | "Session ID unknown"
     233| 2 | "Bad handshake method"
     234| 3 | "Bad request"
     235| 4 | "Forbidden"
     236| 5 | "Unsupported protocol version"
     237
    207238
    208239##### Properties
     
    223254    - **Options**
    224255      - `pingTimeout` (`Number`): how many ms without a pong packet to
    225         consider the connection closed (`5000`)
     256        consider the connection closed (`20000`)
    226257      - `pingInterval` (`Number`): how many ms before sending a new ping
    227258        packet (`25000`)
     
    250281        headers. This cookie might be used for sticky-session. Defaults to not sending any cookie (`false`).
    251282        See [here](https://github.com/jshttp/cookie#options-1) for all supported options.
    252       - `wsEngine` (`String`): what WebSocket server implementation to use. Specified module must conform to the `ws` interface (see [ws module api docs](https://github.com/websockets/ws/blob/master/doc/ws.md)). Default value is `ws`. An alternative c++ addon is also available by installing `uws` module.
     283      - `wsEngine` (`Function`): what WebSocket server implementation to use. Specified module must conform to the `ws` interface (see [ws module api docs](https://github.com/websockets/ws/blob/master/doc/ws.md)). Default value is `ws`. An alternative c++ addon is also available by installing `eiows` module.
    253284      - `cors` (`Object`): the options that will be forwarded to the cors module. See [there](https://github.com/expressjs/cors#configuration-options) for all available options. Defaults to no CORS allowed.
    254285      - `initialPacket` (`Object`): an optional packet which will be concatenated to the handshake packet emitted by Engine.IO.
     
    325356      - `type`: packet type
    326357      - `data`: packet data (if type is message)
     358- `heartbeat`
     359    - Called when `ping` or `pong` packed is received (depends of client version)
    327360
    328361##### Properties
Note: See TracChangeset for help on using the changeset viewer.