google_sign_in_dartio
0.3.0, released 3 years ago by long1.eu
Pure‑Dart Google Sign‑In for Flutter, usable on mobile and desktop.
What it does
Provides a GoogleSignIn implementation that works on all Flutter platforms, including desktop, by handling OAuth flows in Dart. It can register a client ID and optional code‑exchange endpoint, and stores credentials via a custom Store.
AI-written summary of version 0.3.0, based on the package's README and metadata. Report an inaccuracy
Use it when
- Need Google Sign‑In on desktop or web‑like environments where native plugins are unavailable
- Want a single package that works across all Flutter platforms without platform‑specific plugins
Skip it when
- Using FirebaseAuth with the standard google_sign_in plugin
- Running on older Flutter versions that lack desktop support
Strengths
- Pure Dart, no native platform code
- Supports custom credential storage
- Allows code‑exchange endpoint for long‑lived tokens
- Compatible with existing google_sign_in API
Weaknesses
- Requires manual registration of client ID
- Limited to OAuth flows; no support for other auth providers
- Not as battle‑tested as the official plugin
Setup
- Kind
- Flutter widgets
- Effort
- Low
- Code generation
- No
- Direct dependencies
- 10
Add dependency, call GoogleSignInDart.register(clientId: …) before runApp, optionally provide exchangeEndpoint
import 'package:google_sign_in/google_sign_in.dart';
import 'package:google_sign_in_dartio/google_sign_in_dartio.dart';
void main() {
if (isDesktop) {
GoogleSignInDart.register(clientId: '<clientId>');
}
runApp(MyApp());
}
Alternatives
Packages that do the same job and could replace google_sign_in_dartio.
- google_sign_in_ios
iOS and macOS implementation of Google Sign-In for Flutter
90Compare - google_sign_in_android
Android implementation of the google_sign_in plugin
88Compare - firebase_auth
Flutter plugin for Firebase Authentication enabling passwords, phone numbers, and identity providers.
99Compare - google_sign_in_all_platforms
Google Sign-In plugin supporting all platforms including Windows and Linux desktop.
74Compare
Works with
Packages commonly used together with google_sign_in_dartio: ones it builds on, ones built on it, and its own family.
- cryptogoogle_sign_in_dartio depends on itProvides SHA, MD5, and HMAC hashing functions for Dart.
- url_launchergoogle_sign_in_dartio depends on itFlutter plugin for launching URLs across mobile, desktop, and web platforms.
- shared_preferencesgoogle_sign_in_dartio depends on itFlutter plugin for reading and writing simple key-value pairs. Wraps NSUserDefaults on iOS and SharedPreferences on Android.
- google_sign_ingoogle_sign_in_dartio depends on itOfficial Flutter plugin for authenticating users and requesting OAuth scopes via Google Sign-In.
- html_unescapegoogle_sign_in_dartio depends on itUn-escapes HTML-encoded strings supporting named, decimal, and hexadecimal character references.