danasdk 0.0.3 danasdk: ^0.0.3 copied to clipboard
Dana SDK built for Flutter.
import 'package:flutter/material.dart';
import 'package:danasdk/danasdk.dart';
void main() {
runApp(const MyApp());
}
class MyApp extends StatefulWidget {
const MyApp({super.key});
@override
State<MyApp> createState() => _MyAppState();
}
class _MyAppState extends State<MyApp> {
final _danasdkPlugin = Danasdk();
String phone = "EMPLOYER_PHONE";
String companyKey = "YOUR_COMPANY_KEY";
String orgLogo = "YOUR_ORGANIZATION_LOGO_URL";
@override
void initState() {
super.initState();
}
@override
Widget build(BuildContext context) {
return MaterialApp(
home: Scaffold(
appBar: AppBar(
title: const Text("Flutter Wrapper for Dana SDK"),
),
body: Center(
child: ElevatedButton(
onPressed: () {
_danasdkPlugin.runSdk(phone, companyKey, orgLogo);
},
child: const Text("Run SDK"),
),
),
),
);
}
}