DEV Community

Discussion on: Notes on the future of WASM and JS

Collapse
 
redbar0n profile image
Magne • Edited

Another perspective: The Future Web: Will Canvas Rendering Replace the DOM? (paywalled). Which references Google's decision (11. may 2021) to use HTML5 <canvas> for rendering instead of the DOM, for Google Docs, to: "improve performance and improve consistency in how content appears across different platforms". Which seems in line with their Flutter strategy of taking full control over rendering, to avoid platform constraints.

If the DOM is no longer a target, how would this affect WASM vs. JS?

  • JS' benefit of native DOM access would be marginalised.
  • Multi-threading of DOM operations per se would no longer be important. Would multi-threading be very beneficial when targeting something like HTML5 canvas or WebGL with web content? If so, would it mean that JS as a single-threaded language falls out of favor?

(Related: React rendering directly to WebGL? Sebastian Markbåge - DOM as a Second-class Citizen at react-europe 2015)