Add From<String> for image::Handle in iced_web

This commit is contained in:
Héctor Ramón Jiménez 2020-02-06 00:16:59 +01:00
parent 9df3fb13c7
commit ad13b466d2

View file

@ -140,6 +140,12 @@ impl Handle {
}
}
impl From<String> for Handle {
fn from(path: String) -> Handle {
Handle::from_path(path)
}
}
impl From<&str> for Handle {
fn from(path: &str) -> Handle {
Handle::from_path(path)