Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Funnel Report Using Event Properties #3123

Open
mingolladaniele opened this issue Dec 20, 2024 · 1 comment
Open

Funnel Report Using Event Properties #3123

mingolladaniele opened this issue Dec 20, 2024 · 1 comment
Labels
enhancement New feature or request

Comments

@mingolladaniele
Copy link

mingolladaniele commented Dec 20, 2024

Hi,

To maintain a clean events definition, I currently have only a few event_name values, each with specific properties as shown in the code below. However, I would like to generate a funnel report that not only tracks the event names (like click or view) but also leverages the event properties. For example, my click event could occur on different pages or steps of the onboarding process on my platform, and I'd like to track this granularity in the funnel.

Is it already possible to do this? If not, I would appreciate any guidance on how to achieve this functionality.

export declare global {
    interface Window {
        umami?: {
            track: <T extends EventName>(
                eventName: T,
                eventData: EventDataMap[T]
            ) => void;
        };
    }
}

type Page = 'x' | 'y' | 'z';
type Action = 'a' | 'b' | 'c' | 'd';

// Define allowed event names
type EventName = 'c' | 'v';

// Map event names to specific properties
interface EventDataMap {
    click: {
        page: Page;
        type: Action;
        component_name: string;
    };
    view: {
        page: Page;
        step: 'global' | 'checkout_success' | 'checkout_cancel';
        component_type?: 'banner' | 'modal';
    };
}
@mikecao mikecao added the enhancement New feature or request label Dec 26, 2024
@mikecao
Copy link
Collaborator

mikecao commented Dec 26, 2024

We definitely plan to include event data into all the reports.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants