leptos-leaflet 0.10.2

Leaflet components to use in Leptos.
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
/*
 * Copyright (c) HeadlessStudio  2023.
 */
mod js_signals;
mod thread_safe_jsvalue;

pub use js_signals::*;
pub use thread_safe_jsvalue::{ThreadSafeJsValue, IntoThreadSafeJsValue};

pub trait IntoLatLng {
    fn into_lat_lng(self) -> leaflet::LatLng;
}

impl IntoLatLng for (f64, f64) {
    fn into_lat_lng(self) -> leaflet::LatLng {
        leaflet::LatLng::new(self.0, self.1)
    }
}