Add Superwall.track analytics alias for register#420
Closed
claude[bot] wants to merge 1 commit into
Closed
Conversation
Adds a thin fire-and-forget public extension Superwall.track(event, params) that delegates to register(placement = event, params = params) with no handler or feature closure, for sending arbitrary analytics events that are queryable via the Query API.
Author
|
Closing per the thread discussion — we're keeping a single |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Requested by Jake Mor · Slack thread
Changes in this pull request
Superwall.track(event: String, params: Map<String, Any>? = null)next to the existingregisterextension inPublicPresentation.kt.Before: To send an analytics event you had to call
register(placement = ..., params = ...), which is paywall-oriented and exposes ahandlerand afeatureclosure even when you only want fire-and-forget event tracking.After: You can call
Superwall.track("my_event", params)for uncapped, fire-and-forget analytics events. No paywall presentation handling and no feature gating — the event is simply sent to Superwall and is queryable via the Query API. This positions Superwall as an agent-first alternative to Mixpanel/Amplitude/PostHog.How:
trackis a thin alias that delegates directly toregister(placement = event, params = params)withhandler = nulland nofeatureclosure. No registration logic is duplicated.Naming note:
trackwas chosen as the analytics alias to match common analytics-SDK conventions. Reviewers should weigh in if they'd prefertrackEventorregisterEvent.Checklist
CHANGELOG.mdfor any breaking changes, enhancements, or bug fixes.ktlintin the main directory and fixed any issues.Generated by Claude Code