Module Push_js
class type 'a promise = object ... endclass type notification_action = object ... endclass type notification_options = object ... endclass type subscription_options = object ... endclass type notification = object ... endclass type notificationEvent = object ... endclass type pushSubscription = object ... endclass type pushManager = object ... endclass type serviceWorkerRegistration = object ... endclass type serviceWorkerContainer = object ... endclass type pushMessageData = object ... endval notification : notification Js_of_ocaml.Js.t
type notification_action_ml={na_action : string option;na_title : string option;na_icon : string option;}type data= stringtype notifictaion_options_ml={no_actions : notification_action_ml list option;no_body : string option;no_icon : string option;no_tag : string option;no_vibrate : int list option;no_require_interaction : bool option;no_data : data option;}type subscrition_options_ml={so_user_visible_only : bool option;so_application_server_key : string option;}
val jthen : < _then : 'a -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> 'a -> 'bval then1 : < _then : 'a -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> 'a -> unitval then0 : < _then : ('a -> unit) -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> unitval catch : < catch : 'a -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> 'a -> 'bval catch1 : < catch : 'a -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> 'a -> unitval unopt : 'a -> ('b -> 'a) -> 'b option -> 'aval request_permission : (string Js_of_ocaml.Js.t -> unit) -> unitval permission : unit -> stringval service_worker : unit -> serviceWorkerContainer Js_of_ocaml.Js.tval register_worker : string -> (serviceWorkerRegistration Js_of_ocaml.Js.t -> unit) -> unitval get_registration : ?none:(unit -> unit) -> (serviceWorkerRegistration Js_of_ocaml.Js.t -> unit) -> unitval registration : string -> (serviceWorkerRegistration Js_of_ocaml.Js.t -> unit) -> unitval update_service_worker : < update : 'a Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> unitval unregister_service_worker : < unregister : 'a Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> unitval push_manager : < pushManager : < get : 'a; .. > Js_of_ocaml.Js.gen_prop; .. > Js_of_ocaml.Js.t -> 'aval urlBase64ToUint8Array : string -> Js_of_ocaml.Typed_array.uint8Array Js_of_ocaml.Js.tval make_subscription_options : subscrition_options_ml -> subscription_options Js_of_ocaml.Js.tval subscribe : ?options:subscrition_options_ml -> < pushManager : < get : < subscribe : subscription_options Js_of_ocaml.Js.t -> < _then : 'a -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t; .. > Js_of_ocaml.Js.gen_prop; .. > Js_of_ocaml.Js.t -> 'a -> unitval get_subscription : ?none:(unit -> unit) -> < pushManager : < get : < getSubscription : < _then : ('a Js_of_ocaml.Js.Opt.t -> unit) -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t; .. > Js_of_ocaml.Js.gen_prop; .. > Js_of_ocaml.Js.t -> ('a -> unit) -> unitval subscription : ?options:subscrition_options_ml -> < pushManager : < get : < getSubscription : < _then : ('a Js_of_ocaml.Js.Opt.t -> unit) -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t Js_of_ocaml.Js.meth; subscribe : subscription_options Js_of_ocaml.Js.t -> < _then : ('a -> unit) -> 'c Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t; .. > Js_of_ocaml.Js.gen_prop; .. > Js_of_ocaml.Js.t -> ('a -> unit) -> unitval make_notification_action : notification_action_ml -> notification_action Js_of_ocaml.Js.tval make_notification_options : notifictaion_options_ml -> notification_options Js_of_ocaml.Js.tval show_notification : ?options:notifictaion_options_ml -> string -> < showNotification : Js_of_ocaml.Js.js_string Js_of_ocaml.Js.t -> notification_options Js_of_ocaml.Js.t -> < _then : ('a -> unit) -> 'b Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t Js_of_ocaml.Js.meth; .. > Js_of_ocaml.Js.t -> unit