options argument in constructor is optional

This commit is contained in:
Terry Mun
2018-08-01 12:52:32 +02:00
parent 2bf892910b
commit bbfa43d836
+1 -1
View File
@@ -25,7 +25,7 @@ export type EventName = "play" | "pause" | "ended" | "timeupdate" | "progress" |
export type EventCallback = (data: any) => any;
export class Player {
constructor(element: HTMLIFrameElement|HTMLElement|string, options: Options);
constructor(element: HTMLIFrameElement|HTMLElement|string, options?: Options);
on(event: EventName, callback: EventCallback): void;
off(event: EventName, callback?: EventCallback): void;