Live data from Hacker News

Google Docs will now use canvas based rendering

workspaceupdates.googleblog.com

31–40 of 953 posts

Re: Google Docs will now use canvas based rendering

#31

Earlier quoted context omitted.

I want to say that Flutter would be a good candidate, but I don't think it's ready for this. Or is it?

Isn't Flutter intended exactly for this use case? If Google Docs won't use Flutter then I'd say Flutter has failed badly.

I'm a Flutter dev and last time I checked out the web target it resulted in massive bundle sizes and bad performance. This was a couple of months or so ago, but still after their "official" 2.0 release which took web from beta feature to stable.

EDIT: Removed hyperbole: performance was bad, but not unusable

Re: Google Docs will now use canvas based rendering

#32

How will they achieve accessibility? I can only imagine screen readers trying to parse a bunch of vectors.

You can render elements inside of the canvas tag, they simply won't be visible. This gives screen readers something to do, though it becomes trickier since they also have to bugger keyboard shortcuts to implement key navigation for sighted users.

Re: Google Docs will now use canvas based rendering

#33
post #2

This might be a way to make Google Doc's feature that allows copy/paste to be disabled ( https://workspaceupdates.googleblog.com/2015/07/disable-down... ) to be more secure.

but it is false sense of security as any one can screenshot it and use ocr to generate text again?

If a worker circumvents these options being disabled, that's a far worse issue. While before you can say "oh I didn't know", afterwards you can just be fired.

Re: Google Docs will now use canvas based rendering

#34
post #12

I don't build extensions or work on much front end web lately but this reads like Google wants more control over their stuff. The web is becoming less open. > By moving away from HTML-based rendering to a canvas-based rendering, some Chrome extensions may not function as intended on docs.google.com and may need to be updated. > If you are building your own integrations with Google Docs, we recommend using Google Work…

The part I don’t understand is how in the world is a renderer written in JavaScript better performing than their own Chrome c++ code? With Edge being a Chrome clone and Safari being also performant browser, what are they worried about?

Judging from Google Docs' performance, they're already not really using the browser for much.

Re: Google Docs will now use canvas based rendering

#35

RIP web accessibility when everyone starts doing this to make ad blocking more difficult

They won't be able to sell the service in Europe if they ignore web accessibility. The US also have similar laws, or at least people can sue a company if they don't meet the accessibility requirements.

Re: Google Docs will now use canvas based rendering

#36
post #10

I don't build extensions or work on much front end web lately but this reads like Google wants more control over their stuff. The web is becoming less open. > By moving away from HTML-based rendering to a canvas-based rendering, some Chrome extensions may not function as intended on docs.google.com and may need to be updated. > If you are building your own integrations with Google Docs, we recommend using Google Work…

> I'd like to know if there are reasons to move to canvas for strictly technical merits. In Google's announcements, they say the reason is performance.

That seems like a moderately weak argument. DOM tables are slow, but if you know what you are doing the DOM is otherwise an insanely fast interface. You can get sub-nanosecond response speed from DOM calls in Firefox (faster than a billion operations per second).

It would be interesting to see the performance differences in numbers. The performance impact of a canvas based approach can be approximated from measuring the performance of heavy SVG animations on GPU load.

Re: Google Docs will now use canvas based rendering

#39

RIP web accessibility when everyone starts doing this to make ad blocking more difficult

Eh, I'll believe the slippery slope when I see it. Right now I think this move makes total sense since the dom is currently just being used as a rendering target and has to implement all its document-y behavior itself. Nothing about Google Docs uses the dom semantically and it already has to implement all its own accessibility support itself because without a lot of help screen readers would be useless.

Re: Google Docs will now use canvas based rendering

#40

I don't build extensions or work on much front end web lately but this reads like Google wants more control over their stuff. The web is becoming less open. > By moving away from HTML-based rendering to a canvas-based rendering, some Chrome extensions may not function as intended on docs.google.com and may need to be updated. > If you are building your own integrations with Google Docs, we recommend using Google Work…

> For those more deep in web technology, I'd like to know if there are reasons to move to canvas for strictly technical merits.

We’ll see the results, but let’s be honest - web is bad fit for apps. It was never designed for it, and has tons of hacks and layers to make it possible, that makes them messy and slow.

Post reply on HN