What do you suggest as an alternative? Writing only Linux apps?
Chrome was to the web what Windows was to the desktop PC: It made writing mainstream apps with wide distribution practical. It's not like devs were held hostage. They saw an opportunity in this new platform and flocked to it because it was so good. Finally, a way to write an app and deliver it to users across devices, mostly unchanged. Write once (well, really more like 1.3x), run anywhere.
Chrome was a huge improvement over IE and by-then-bloated Firefox, and Gmail and Google Maps and Google Docs good early demonstrators of what the Web could be (yes, they bought many of those, but that's not too relevant here).
Web technologies were still an uncertain bet back in the day, competing against Java, ActiveX, Flash, and plain old PHP/Coldfusion/ASP apps, or even .NET and ClickOnce, etc. Chrome and V8 largely enabled the web and JS to slowly gain traction, alongside the growing ecosystem of JS libraries and frameworks.
The future, then as now, wasn't "FOSS GNU/Linux against Google's web". It was big company against big company. Even now, if it wasn't for the Web and Android, we'd simply have iOS supremacy instead of Windows.
Linux doesn't gain mainstream traction among normal users because its desktop experience is relatively poor, thanks to a historical focus on engineering prowess and ideology over end user UX. It only succeeds when big companies build on top of it and polish it a lot (Android, Steam Deck, Ubuntu, ChromeOS). That's not Google's fault, it's just what the Linux community prioritizes.
Even today, it's amazing that the Web is still largely visible source of HTML and React. And it's contributed to by a bunch of companies, from Meta to Vercel to Cloudflare to Amazon to Oracle to to tens of thousands of small businesses and NPM contributors. This is already vastly more open than iOS and Android apps, at least until WASM closes everything off again. And though Google has definitively won the browser wars, Blink and Webkit are still far more similar than any other two platforms. It's easier to develop for two browsers than even two Linux distros / package managers.
Is it shortsighted? I think it's just going where the users are. And the users are typically going to choose ease of use over strict ideology. This shit isn't their passion. They don't spend their days pondering the virtues and vices of operating systems and licenses. It's just a phone. And to most devs, it's just a platform.
People are practical creatures. They'll use and write apps where other people are. Ideology will never be enough to change that. Usability and popularity might.