Skip to content

Mattel/magic-flutter

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

magic-flutter

Magic empowers developers to protect their users via an innovative, passwordless authentication flow without the UX compromises that burden traditional OAuth implementations.

⚠️ Device Registration Requirement ⚠️

As of v4.1.0, users will be asked to go through a device registration flow to securely confirm any new device they use to login. If you run into this issue, please consider upgrading to the latest version of the SDK.

Get started

Install Flutter & Dart https://flutter.dev/docs/get-started/install

Start the project

$ cd project_root/magic_demo
$ flutter run

Dependency installation is automatically done in the flutter run command

For detail integration please check our official doc or README in each package directory

Package Name Changelog Description
magic_sdk CHANGELOG Flutter entry-point for Magic SDK.
magic_ext_oauth CHANGELOG An Extension to access OAuth providers
magic_ext_tezos CHANGELOG Tezos blockchain extension that integrates with Tezart
magic_ext_solana CHANGELOG Solana blockchain extension that integrates with crypto-please/solana
magic_ext_oidc CHANGELOG Magic Open Id Connect SDK extension for Flutter

Blockchain access

Make sure you have the third-party blockchain dependencies installed

  • Tezos via Tezart
  • Solana via Crypto-please/solana

You may remove these dependencies if you don't need to access these chains

Development Caveats

Files ending with *.g.dart are auto generated type files that are used to serialize / deserialize a class. To generate a new sets of files to reflect your changes please run the command below at your/path/to/magic_sdk

$ dart run build_runner build --delete-conflicting-outputs

Proguard rules

Relates to issue #43.

Add a proguard-rules.pro file under your android/app folder (or update your existing one), with the following rule:

# Preserve annotated Javascript interface methods.
-keepclassmembers class * {
    @android.webkit.JavascriptInterface <methods>;
}

Example: Magic Flutter Demo App

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Dart 93.0%
  • HTML 3.9%
  • Ruby 1.4%
  • Shell 1.2%
  • Swift 0.4%
  • Kotlin 0.1%