adapty_flutter 2.10.3 adapty_flutter: ^2.10.3 copied to clipboard
Adapty SDK is an open-source framework that makes implementing in-app subscriptions in Flutter applications fast and easy. It’s 100% open-source and lightweight.
import 'package:adapty_flutter_example/purchase_observer.dart';
import 'package:flutter/cupertino.dart';
import 'screens/main_screen.dart';
void main() {
runApp(MyApp());
}
class MyApp extends StatefulWidget {
@override
_MyAppState createState() => _MyAppState();
}
class _MyAppState extends State<MyApp> {
@override
void initState() {
PurchasesObserver().initialize();
super.initState();
}
Widget build(BuildContext context) {
return CupertinoApp(
theme: CupertinoThemeData(
brightness: Brightness.light,
scaffoldBackgroundColor: CupertinoColors.systemGroupedBackground,
),
home: MainScreen(),
);
}
}