split modules and fix Ev

This commit is contained in:
Swrup 2022-04-07 14:45:11 +02:00
parent 2154a10db4
commit 82d74ad985
18 changed files with 208 additions and 225 deletions

11
src/marker.ml Normal file
View file

@ -0,0 +1,11 @@
type t = Jv.t
let create latlng = Jv.call Global.leaflet "marker" [| Latlng.to_jv_t latlng |]
let add_to marker map = ignore @@ Jv.call marker "addTo" [| Map.to_jv_t map |]
let bind_popup el marker =
ignore @@ Jv.call marker "bindPopup" [| Brr.El.to_jv el |];
marker
let open_popup marker = ignore @@ Jv.call marker "openPopup" [||]