![]() ![]() “If you actually played with the version of Google Docs, you’ll notice that it actually works very similar to the current DOM version. Given the accessibility limitations, they created a “side DOM to handle accessibility.” He confirmed that this is the approach Google Docs has taken too. They chose to use Canvas because of the performance benefits it offered. The pair were asked by moderator Jake Archibald, somewhat tongue in cheek, “is the DOM dead?”Īlmaer began by discussing an online code editor that he and his colleague Ben Galbraith launched in 2009 when they worked at Mozilla, called Bespin - which was also Canvas based. The canvas rendering change was discussed at last week’s Google I/O, the company’s annual developer conference, in an “ask me anything” (AMA) session with Google’s Dion Almaer (Director, Web Developer Ecosystem) and Paul Kinlan (Global Lead, Chrome Developer Relations). With Canvas, it’s more like a big blob of code than a tree. With the DOM’s tree structure, each node is an object representing a part of the document. Accessibilityīut what about the accessibility concerns? Drawing on a canvas means you don’t have the semantic underlay that working with the DOM provides. So this isn’t a brand new development, rather it is an approach that Google has iterated on over time. It’s also how Google Sheets renders content. ![]() MacDonald pointed out that Google Maps has been doing canvas rendering for years and that it’s the default approach in Google’s cross-platform Flutter toolkit. ![]() “It now feels like the familiar pattern - downloading plaintext JavaScript code and executing it against an inspectable HTML document - might just be a brief stop in the ever-evolving road of web development.” As Matthew MacDonald put it in an excellent article on the Young Coder blog: What makes this intriguing is that the Google Docs shift to canvas rendering may be an early sign of a bigger change in how web applications are built. The appeal of Canvas is that it enables the developers of Google Docs to bypass all of that persnickety DOM wrangling and just “paint” the document onto the page. However, an online word processor requires a lot of precise rendering of objects on a page, which is difficult to do via the DOM. Up till now, Google Docs had evolved over the past fifteen years in the familiar pattern of most web applications: its interactivity largely achieved by heavy use of JavaScript code to manipulate the DOM. The bigger question, though, is what - if any - impact this change will have on how other web applications are built? Since Google is such a force in modern web development (Chrome being the dominant browser on the web), some are wondering if this shift to Canvas sets a bad precedent. ![]() Google says the change to Canvas rendering will “improve performance and improve consistency in how content appears across different platforms.” It has immediate implications for developers of Chrome extensions, however, Google has given guidance on how extensions can be ported to the new framework. Previously he founded ReadWriteWeb in 2003 and built it into one of the world’s most influential technology news and analysis sites. Richard is senior editor at The New Stack and writes a weekly column about web and application development trends. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |