azuread_login_view 0.6.1 copy "azuread_login_view: ^0.6.1" to clipboard
azuread_login_view: ^0.6.1 copied to clipboard

Provides one or more widgets to handle OAuth logins via Azure Active Directory.

pub package Publish

Flutter widget using webview_flutter and http, which provides one or more widgets to handle OAuth logins via Azure Active Directory.

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

void main() {
  runApp(const MyLoginExamplePage());
}

class MyLoginExamplePage extends StatelessWidget {
  @override
  Widget build(BuildContext context) {
    final AzureADLoginViewOptions loginViewOptions = AzureADLoginViewOptionsBuilder()
      // setup required settings
      .setTenant("<TENANT-NAME-OR-ID>")
      .setClientId("<CLIENT-ID>")
      .setRedirectUri("<REDIRECT-URI>")
      .setLoginPolicy("<NAME-OF-LOGIN-POLICY>")
      .setOnNewTokens((AzureADLoginNewTokensHandlerContext context) {
         // s. `context.tokens`
       })

      // this is optional
      .setOnNavigationError((AzureADLoginNavigationErrorHandlerContext context) {
         // ...
       })

      .build();

    return MaterialApp(
      home: AzureADLoginView(loginViewOptions),
    );
  }
}

An example application can be found inside example folder.

1
likes
130
pub points
18%
popularity

Publisher

verified publishere-go-mobile.de

Provides one or more widgets to handle OAuth logins via Azure Active Directory.

Repository (GitHub)
View/report issues

Documentation

API reference

License

LGPL-3.0 (LICENSE)

Dependencies

flutter, http, webview_flutter

More

Packages that depend on azuread_login_view