supabase_addons 0.0.7+1 copy "supabase_addons: ^0.0.7+1" to clipboard
supabase_addons: ^0.0.7+1 copied to clipboard

Addons to supabase dart (and Flutter), to make development easier.

example/supabase_addons_example.dart

import 'dart:async';

import 'package:supabase/supabase.dart';
import 'package:supabase_addons/supabase_addons.dart';

import 'credentials.dart';

void main() async {
  // Intialize the addons
  await SupabaseAddons.initialize(
      client: SupabaseClient(SUPABASE_URL, SUPABASE_SECRET),
      appVersion: '0.1.0');
  SupabaseCrashlyticsAddons.initialize();

  // Run the app
  await runZonedGuarded<Future<void>>(() async {
    if (SupabaseAuthAddons.auth.currentSession == null) {
      print('No user found. Signing the user in');
      await SupabaseAuthAddons.auth.signIn(email: EMAIL, password: PASSWORD);
    } else {
      print('User found on the storage.');
    }

    // un(comment) the following line to disable the crashlytics testing
    throw 'test crashlytics';

    // Dipose the addons
  }, (error, stacktrace) {
    SupabaseCrashlyticsAddons.recordError(error, stacktrace);
  });

  // Dispose the addons
  // SupabaseAddons.dispose();
  // exit(0)
}
26
likes
130
points
37
downloads

Publisher

unverified uploader

Weekly Downloads

Addons to supabase dart (and Flutter), to make development easier.

Repository (GitHub)
View/report issues

Documentation

API reference

License

BSD-3-Clause (license)

Dependencies

hive, intl, stack_trace, supabase

More

Packages that depend on supabase_addons