interface dom.EventSource
implements EventTarget
import { type dom } from "https://deno.land/x/evt@v2.4.20/mod.ts";
const { EventSource } = dom;
Properties
onerror: ((this: EventSource, ev: Event) => any) | null
onmessage: ((this: EventSource, ev: MessageEvent) => any) | null
onopen: ((this: EventSource, ev: Event) => any) | null
Methods
Aborts any instances of the fetch algorithm started for this EventSource object, and sets the readyState attribute to CLOSED.
addEventListener<K extends keyof EventSourceEventMap>(): void
type: K,
listener: (this: EventSource, ev: EventSourceEventMap[K]) => any,
options?: boolean | AddEventListenerOptions,
addEventListener(): void
type: string,
listener: EventListenerOrEventListenerObject,
options?: boolean | AddEventListenerOptions,
removeEventListener<K extends keyof EventSourceEventMap>(): void
type: K,
listener: (this: EventSource, ev: EventSourceEventMap[K]) => any,
options?: boolean | EventListenerOptions,