PHP 7.4.33
Preview: WebSocketEvent.js Size: 719 B
/var/www/uibuilder.cmshelp.dk/httpdocs/node_modules/react-native/Libraries/WebSocket/WebSocketEvent.js
/**
 * Copyright (c) Meta Platforms, Inc. and affiliates.
 *
 * This source code is licensed under the MIT license found in the
 * LICENSE file in the root directory of this source tree.
 *
 * @format
 * @flow strict-local
 */

'use strict';

/**
 * Event object passed to the `onopen`, `onclose`, `onmessage`, `onerror`
 * callbacks of `WebSocket`.
 *
 * The `type` property is "open", "close", "message", "error" respectively.
 *
 * In case of "message", the `data` property contains the incoming data.
 */
class WebSocketEvent {
  type: string;

  constructor(type: string, eventInitDict: $FlowFixMe) {
    this.type = type.toString();
    Object.assign(this, eventInitDict);
  }
}

module.exports = WebSocketEvent;

Directory Contents

Dirs: 1 × Files: 6
Name Size Perms Modified Actions
__mocks__ DIR
- drwxr-xr-x 2025-03-28 11:04:42
Edit Download
428 B lrw-r--r-- 2025-03-28 11:04:42
Edit Download
1.28 KB lrw-r--r-- 2025-03-28 11:04:41
Edit Download
2.21 KB lrw-r--r-- 2025-03-28 11:04:43
Edit Download
8.82 KB lrw-r--r-- 2025-03-28 11:04:42
Edit Download
719 B lrw-r--r-- 2025-03-28 11:04:42
Edit Download
7.24 KB lrw-r--r-- 2025-03-28 11:04:42
Edit Download
If ZipArchive is unavailable, a .tar will be created (no compression).