fix: correct re-exports for islands with props (closes #2723)
This commit is contained in:
parent
1c05389707
commit
30cf1167f2
|
@ -296,10 +296,17 @@ pub mod spawn {
|
|||
}
|
||||
}
|
||||
|
||||
// these reexports are used in islands
|
||||
#[cfg(feature = "experimental-islands")]
|
||||
#[doc(hidden)]
|
||||
pub use wasm_bindgen; // used in islands
|
||||
pub use serde;
|
||||
#[cfg(feature = "experimental-islands")]
|
||||
#[doc(hidden)]
|
||||
pub use web_sys; // used in islands
|
||||
pub use serde_json;
|
||||
#[doc(hidden)]
|
||||
pub use wasm_bindgen;
|
||||
#[doc(hidden)]
|
||||
pub use web_sys;
|
||||
|
||||
/*mod additional_attributes;
|
||||
pub use additional_attributes::*;
|
||||
|
|
|
@ -375,16 +375,15 @@ impl ToTokens for Model {
|
|||
} else {
|
||||
quote! {}
|
||||
};
|
||||
let deserialize_island_props = quote! {}; /*if is_island_with_other_props {
|
||||
let deserialize_island_props = if is_island_with_other_props {
|
||||
quote! {
|
||||
let props = el.dataset().get("props") // TODO ::leptos::wasm_bindgen::intern("props"))
|
||||
let props = el.dataset().get(::leptos::wasm_bindgen::intern("props"))
|
||||
.and_then(|data| ::leptos::serde_json::from_str::<#props_serialized_name>(&data).ok())
|
||||
.expect("could not deserialize props");
|
||||
}
|
||||
} else {
|
||||
quote! {}
|
||||
};*/
|
||||
// TODO
|
||||
};
|
||||
|
||||
quote! {
|
||||
#[::leptos::wasm_bindgen::prelude::wasm_bindgen(wasm_bindgen = ::leptos::wasm_bindgen)]
|
||||
|
|
|
@ -42,6 +42,7 @@ web-sys = { version = "0.3", features = [
|
|||
"CssStyleDeclaration",
|
||||
"ShadowRoot",
|
||||
"HtmlCollection",
|
||||
"DomStringMap",
|
||||
|
||||
# Events we cast to in leptos_macro -- added here so we don't force users to import them
|
||||
"AddEventListenerOptions",
|
||||
|
|
Loading…
Reference in New Issue