mirror of
https://gitcode.com/gh_mirrors/hy/Hydro.git
synced 2026-10-20 01:38:19 +08:00
fix types
This commit is contained in:
7 files changed
+11
-18
No files matched your search
@@ -1,9 +1,9 @@
|
||||
/* eslint-disable no-restricted-globals */
|
||||
/// <reference no-default-lib="true" />
|
||||
/// <reference lib="ES2015" />
|
||||
/// <reference types="@types/sharedworker" />
|
||||
/// <reference lib="webworker" />
|
||||
import ReconnectingWebsocket from 'reconnecting-websocket';
|
||||
import { FLAG_INFO } from 'vj/constant/message';
|
||||
declare const self: SharedWorkerGlobalScope;
|
||||
|
||||
console.log('SharedWorker init');
|
||||
|
||||
@@ -75,7 +75,7 @@ function initConn(path: string, port: MessagePort, cookie: any) {
|
||||
};
|
||||
}
|
||||
|
||||
onconnect = function (e) { // eslint-disable-line no-undef
|
||||
self.onconnect = function (e) { // eslint-disable-line no-undef
|
||||
const port = e.ports[0];
|
||||
|
||||
port.addEventListener('message', (msg: { data: RequestPayload }) => {
|
||||
|
||||
Reference in new issue
Block a user