gms_check 1.1.0 copy "gms_check: ^1.1.0" to clipboard
gms_check: ^1.1.0 copied to clipboard

PlatformAndroid

This tiny plugin simply check if Google Services is avalable in the Android device.

example/lib/main.dart

import 'dart:async';

import 'package:flutter/material.dart';
import 'package:gms_check/gms_check.dart';

Future<void> main() async {
  /// Need to call GmsCheck().checkGmsAvailability()
  /// only once before runApp function.
  await GmsCheck().checkGmsAvailability();

  runApp(const MyApp());
}

class MyApp extends StatefulWidget {
  const MyApp({super.key});

  @override
  State<MyApp> createState() => _MyAppState();
}

class _MyAppState extends State<MyApp> {
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      home: Scaffold(
        appBar: AppBar(title: const Text('Plugin example app')),
        body: Center(
          child: Text('GMS available: ${GmsCheck().isGmsAvailable}\n'),
        ),
      ),
    );
  }
}
9
likes
160
points
6.26k
downloads

Documentation

API reference

Publisher

verified publishersofluffy.io

Weekly Downloads

This tiny plugin simply check if Google Services is avalable in the Android device.

Repository (GitHub)
View/report issues

License

Apache-2.0 (license)

Dependencies

flutter

More

Packages that depend on gms_check

Packages that implement gms_check