Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make NodeRef API Compatible with wasm-bindgen #740

Closed
anlumo opened this issue Nov 14, 2019 · 1 comment
Closed

Make NodeRef API Compatible with wasm-bindgen #740

anlumo opened this issue Nov 14, 2019 · 1 comment

Comments

@anlumo
Copy link

anlumo commented Nov 14, 2019

Description

Feature request: I'm trying to integrate a crate that uses wasm_bindgen types to interact with the DOM. For this, components need to be able to pass these references to functions of this crate. However, the current NodeRef API only returns DOM elements wrapped by stdweb, which are incompatible.

I've spent a few hours now looking into ways to directly convert between stdweb::webapi::node::Node and web_sys::Element, but apparently there is none whatsoever.

Expected Results

Maybe a NodeRefBindgen type that works in the same way NodeRef works right now.

Actual Results

There's only NodeRef.

Context (Environment)

  • yew: v0.10.0
  • target: wasm32-unknown-unknown
@jstarry
Copy link
Member

jstarry commented Nov 14, 2019

Hey there @anlumo, thanks for the issue! We have an issue tracking web-sys support here: #558. It needs some love 😛 but will get done soonish! When it is done, it will make NodeRef web-sys compatible as you are requesting.

@jstarry jstarry closed this as completed Nov 14, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants