captureEvent function

Future<void> captureEvent(
  1. String eventName, {
  2. Map<String, Object>? properties,
})

Captures a posthog event.

Implementation

Future<void> captureEvent(String eventName, {Map<String, Object>? properties}) {
  final posthog = Modular.get<PostHog>();

  return posthog.capture(eventName: eventName, properties: properties);
}