Skip to content

Comment on Everything about Google Translate crashing React (and other web apps)parent

Comments

I disagree. The browser is a VM that runs other applications, in this case one that's written in React.

Then the browser, via an extension, is corrupting that application's internal state and is then surprised when that application stops working correctly. Well, duh.

If Translate were to only modify the text on the website, I'd think React would be able to deal with it better. But it seems to be modifying the structure too (adding <font> tags); I think it's not reasonable to expect every JS framework to be able to deal with that properly.

The browser extension is not touching "application's" state whatsoever. The browser extension is, however, making a perfectly legal store on a shared system resource (if you consider browser to be VM), but the application ignores those modifications and continues to issue state modification calls computed from it's own, now long invalidated, internal cache.

I think it's not reasonable to expect every JS framework to be able to deal with that properly.

It would be unreasonable to call any framework out of pre-alpha prototype stage, much less production ready, if it can't handle such basic stuff, sorry.

I disagree with that. Fundamentally, it comes down to who is in charge. Does React control the DOM or does the DOM control react? I see this as a cache concurrency issue--React is trying to cache the DOM and breaking when that fails.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.