stripe_payment
Today, the online payment function is more popular than ever. As we live in a technology age, online payment becomes necessary. Sometimes we wonder how to create widgets that support that? Is it easy? Or extremely difficult?
This is a flutter plugin to integrate the stripe plugin very matching for iOS and Android operating systems. Currently, only adding a credit card as the source is implemented.


Usage
To set your publishable key set:
import 'package:stripe_payment/stripe_payment.dart';
StripeSource.setPublishableKey("pk_test");
from somewhere in your code, e.g. your main.dart file.
To open the dialog:
StripeSource.addSource().then((String token) {
print(token); //your stripe card source token
});
Android
Please be aware that your main activity must extend from FlutterFragmentActivity. Otherwise the Android dialog would’ve looked very nasty.
TODO
- [ ] better error handling
- [ ] internationalization
- [ ] more stripe library implementations?
GitHub
https://github.com/jonasbark/flutter_stripe_payment