Selaa lähdekoodia

fix desktop and liveview compilation

Evan Almloff 1 vuosi sitten
vanhempi
commit
62556b2c34

+ 1 - 1
packages/desktop/Cargo.toml

@@ -11,7 +11,7 @@ keywords = ["dom", "ui", "gui", "react"]
 
 [dependencies]
 dioxus-core = { workspace = true, features = ["serialize"] }
-dioxus-html = { workspace = true, features = ["serialize", "native-bind"] }
+dioxus-html = { workspace = true, features = ["serialize", "native-bind", "mounted", "eval"] }
 dioxus-interpreter-js = { workspace = true }
 dioxus-hot-reload = { workspace = true, optional = true }
 

+ 1 - 1
packages/liveview/Cargo.toml

@@ -22,7 +22,7 @@ tokio-stream = { version = "0.1.11", features = ["net"] }
 tokio-util = { version = "0.7.4", features = ["rt"] }
 serde = { version = "1.0.151", features = ["derive"] }
 serde_json = "1.0.91"
-dioxus-html = { workspace = true, features = ["serialize"] }
+dioxus-html = { workspace = true, features = ["serialize", "eval", "mounted"] }
 dioxus-core = { workspace = true, features = ["serialize"] }
 dioxus-interpreter-js = { workspace = true }
 dioxus-hot-reload = { workspace = true, optional = true }

+ 2 - 2
packages/liveview/src/element.rs

@@ -16,8 +16,8 @@ impl LiveviewElement {
 }
 
 impl RenderedElementBacking for LiveviewElement {
-    fn get_raw_element(&self) -> dioxus_html::MountedResult<&dyn std::any::Any> {
-        Ok(self)
+    fn as_any(&self) -> &dyn std::any::Any {
+        self
     }
 
     fn get_client_rect(