SmartCheckoutConfig.from constructor
SmartCheckoutConfig.from(
- Map map
Implementation
factory SmartCheckoutConfig.from(Map map) {
try {
return SmartCheckoutConfig(
environment: (map['environment'] as String).toEnvironment(),
sessionCode: map['sessionCode'] as String?,
partnerKey: map['partnerKey'] as String?,
deepLink: (map['deepLink'] as String?)?.toUri(),
initialHeightFraction: map['initialHeightFraction'] as double?,
style: (map['style'] as String?)?.toStyle(),
);
} catch (e) {
throw ArgumentError('Failed to convert map to config: $e');
}
}