Insights constructor
Implementation
factory Insights({
required String applicationID,
required String apiKey,
String? region,
}) {
if (_insightsPool.containsKey(applicationID)) {
return _insightsPool[applicationID]!;
}
final insights = Insights.custom(
AlgoliaEventService(
applicationID: applicationID,
apiKey: apiKey,
region: region,
),
UserTokenStorage(),
);
_insightsPool[applicationID] = insights;
return insights;
}