3 ms·
Check out Rust’s wasm-bindgen - https://github.com/rustwasm/wasm-bindgen https://github.com/rustwasm/wasm-bindgen if ya haven’t already. Right now it you call
by chinedufn 8y ago
Check out Rust’s wasm-bindgen - https://github.com/rustwasm/wasm-bindgen https://github.com/rustwasm/wasm-bindgen if ya haven’t already.
Right now it you call into JS to interact with the DOM but when the host bindings proposal sees fruit it’ll replace the JS shims with direct DOM manipulation!
- seanmcdirmid 8y agoIt isn’t clear how they will allow safe access to the DOM without GC. Maybe they’ll take an approach like Microsoft did with UWP and use reference counting?
- tjallingt 8y agoWould be interesting if it would be possible to take the Rust approach and guarantee at parse/compilation time that the DOM interactions are safe without runtime overhead. Probably a terrible idea for mobile devices though...
- seanmcdirmid 8y agoThat would only work if it isn’t shared with unsafe code.