Use path directly in svg example

This commit is contained in:
Héctor Ramón Jiménez 2025-11-21 21:48:22 +01:00
parent c67f523818
commit 43077364c5
No known key found for this signature in database
GPG key ID: 7CC46565708259A7

View file

@ -25,13 +25,8 @@ impl Tiger {
} }
fn view(&self) -> Element<'_, Message> { fn view(&self) -> Element<'_, Message> {
let handle = svg::Handle::from_path(concat!(
env!("CARGO_MANIFEST_DIR"),
"/resources/tiger.svg",
));
let svg = let svg =
svg(handle) svg(concat!(env!("CARGO_MANIFEST_DIR"), "/resources/tiger.svg",))
.width(Fill) .width(Fill)
.height(Fill) .height(Fill)
.style(|_theme, _status| svg::Style { .style(|_theme, _status| svg::Style {