Vanethos / flutter_connectivity_widget

A widget that shows the user if the phone is connected to the internet or not
BSD 2-Clause "Simplified" License
68 stars 35 forks source link

Disable checking if flutter web #20

Closed chitgoks closed 4 years ago

chitgoks commented 4 years ago

yes. the lib is not supported in web. but to keep the same code, would it be possible to somehow detect that if it is kIsWeb, then the stream builder will just ignore connections so that the ConnectivityWidget(builder: (context, isOnline) { }) will still be embedded in the build widget even if it is deployed for flutter web

rather than doing a workaround now to add the widget if it is not web.

Vanethos commented 4 years ago

What if we are using this in a PWA that supports offline usage?

chitgoks commented 4 years ago

is that for me? sorry whats pwa?

Vanethos commented 4 years ago

Progressive Web App

https://web.dev/progressive-web-apps/

As such we can have web apps that have offline functionality