|
|
|
|
|
by themacguffinman
1928 days ago
|
|
Supporting new and unique APIs/inputs/etc like WebVR is a pretty classic cross-platform problem and it's usually addressed by allowing native hooks. Flutter has MethodChannels which let you call native methods in the underlying "platform host". It also supports "PlatformViews" which let you embed native widgets. It doesn't really need to have instant parity with "native" web apps at everything. Maybe Flutter is a poor fit if you have extensive native requirements. That's okay. |
|
Currently as a web dev, if I want my website to be usable by a voice assistant, I don't have to do anything. If I want my website to be usable in VR, I don't have to think about it -- that's Chrome's problem, not mine, I just expose the exact same controls I've always used. If someone is building a user agent that interacts with my site in a novel way, as long as I've built my site well everything just kind of works, because of how the web is architectured.
But if you're rebuilding all of the controls from scratch, suddenly you can't think that way anymore. You have to think about the controls and gestures that every medium exposes, or else you have a website that just randomly breaks depending on what OS/platform a user accesses it from.
> and it's usually addressed by allowing native hooks
Not on the web though. I mean, for obvious reasons on the web we can't just expose native OS methods for websites to call. Flutter doesn't have a choice on that front, Google, Mozilla, and Apple realistically aren't going to break browser sandboxing just so the devs have an easier time.