network_type_reachability 1.0.1
network_type_reachability: ^1.0.1 copied to clipboard
This plugin allows Flutter applications to detect network changes. You can know the detailed mobile network types such as 2G, 3G, 4G, 5G. This plug-in is suitable for iOS and Android
Use this package as a library
Depend on it
Run this command:
With Flutter:
$ flutter pub add network_type_reachability
This will add a line like this to your package's pubspec.yaml (and run an implicit flutter pub get
):
dependencies:
network_type_reachability: ^1.0.1
Alternatively, your editor might support flutter pub get
. Check the docs for your editor to learn more.
Import it
Now in your Dart code, you can use:
import 'package:network_type_reachability/network_type_reachability.dart';