@junobuild/analytics
Version:
Tracker for Juno analytics
10 lines (9 loc) • 598 B
TypeScript
import type { UserEnvironment } from './types/env';
export { trackEvent, trackPageView } from './services/analytics.services';
export type * from './types/env';
/**
* Initializes the Juno Analytics.
* @param {UserEnvironment} [userEnv] - The optional user environment configuration. If no environment is provided, the variables injected by the Vite or NextJS plugins will be used.
* @returns {Promise<() => void>} A promise that resolves to a cleanup function that stops tracking and cleans up resources.
*/
export declare const initOrbiter: (userEnv?: UserEnvironment) => Promise<() => void>;