Skip to content

Commit 31925f2

Browse files
authored
Generic error event for EventSource
According to MDN the error of an EventSource is a generic Event instead of an ErrorEvent: https://developer.mozilla.org/en-US/docs/Web/API/EventSource/error_event
1 parent efe1b87 commit 31925f2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

dom/src/main/scala/org/scalajs/dom/EventSource.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ class EventSource private[this] extends EventTarget {
4141

4242
var onmessage: js.Function1[MessageEvent, _] = js.native
4343

44-
var onerror: js.Function1[ErrorEvent, _] = js.native
44+
var onerror: js.Function1[Event, _] = js.native
4545

4646
/** The close() method must abort any instances of the fetch algorithm started for this EventSource object, and must
4747
* set the readyState attribute to CLOSED. W3C 2012

0 commit comments

Comments
 (0)