frameworks using webassembly
play

frameworks using WebAssembly Boyan Mihaylov @boyanio boyan.io - PowerPoint PPT Presentation

The rise of non-JavaScript frameworks using WebAssembly Boyan Mihaylov @boyanio boyan.io WebAssembly ( WASM ) is compiler target for programs on the Web @boyanio @boyanio https://vimeo.com/272924131 The Web of JavaScript frameworks


  1. The rise of non-JavaScript frameworks using WebAssembly Boyan Mihaylov @boyanio boyan.io

  2. WebAssembly ( WASM ) is compiler target for programs on the Web @boyanio

  3. @boyanio https://vimeo.com/272924131

  4. The Web of JavaScript frameworks @boyanio

  5. JavaScript frameworks architecture fetch compile Your code .js / .ts .js .html Compiled app HTML page fetch JavaScript Framework .js @boyanio

  6. How would WebAssembly influence the way we do Web development today? @boyanio

  7. Rewriting existing JavaScript frameworks into a language 1 that can be compiled to WebAssembly @boyanio

  8. WebAssembly-compiled frameworks initialize fetch compile Your code .cpp .wasm .js .html JavaScript Compiled HTML page glue code app Framework’s code .cpp @boyanio

  9. C++/Python → JavaScript → C++/Python @boyanio https://www.tynwiz.com

  10. No direct DOM access index.c main.js extern void createElement (void); const imports = { createElement : () => { int main(void) document.createElement (‘div’); { } createElement(); }; createElement(); … WebAssembly.instantiate (…, imports); return 0; } @boyanio

  11. JavaScript → WebAssembly overhead Firefox 60+ Firefox @boyanio https://blog.benj.me/2018/07/04/mozilla-2018-faster-calls-and-anyref/

  12. Easier to create fast native mobile apps @boyanio

  13. Rewriting parts of existing JavaScript frameworks into 2 a language that can be compiled to WebAssembly @boyanio

  14. @boyanio

  15. https://github.com/vuejs/vue/issues/8193 https://github.com/glimmerjs/glimmer-vm/pull/752 @boyanio

  16. Writing custom components in a language that can be 3 compiled to WebAssembly @boyanio

  17. Angular & WebAssembly https://boyan.io/angular-wasm/ @boyanio

  18. Emergence of non-JavaScript 4 frameworks using WebAssembly @boyanio

  19. Blazor https://blazor.net @boyanio

  20. Traditional .NET architecture load IL compile metadata Source code MyApp.dll CLR JIT compilation .NET Framework to native code Native @boyanio

  21. Blazor architecture load IL compile metadata Source code MyApp.dll mono.wasm execute Blazor.dll Browser netstandard compiled by browser’s VM Native @boyanio

  22. React vs. Blazor https://boyan.io/react-blazor/ @boyanio

  23. Application structure React Blazor @boyanio

  24. Application structure React (Root.jsx) Blazor (Root.razor) @page “/” … render() { <div> return ( <h1>Blazor chat</h1> <div> <NewChatMessage /> <h1>React chat</h1> <Chat … /> <NewChatMessage /> </div> <Chat … /> </div> ); } } @boyanio

  25. @boyanio https://devblogs.microsoft.com/aspnet/blazor-now-in-official-preview/

  26. Blazor-inspired framework in Go https://github.com/bketelsen/wasmplay @boyanio

  27. React-inspired framework in Rust https://github.com/DenisKolodin/yew @boyanio

  28. WebAssembly enables different languages to work together on the Web https://boyan.io/wasm-wheel/ @boyanio

  29. The future of Web belongs to those, who compile Boyan Mihaylov / @boyanio / boyan.io

Recommend


More recommend