Overview
track() is the core function of Analytiq. Call it whenever something meaningful happens in your app — a page visit, a button click, a purchase, a form submission.
Each event gets saved to your dashboard instantly.
Signature
Parameters
Properties value types
Properties can only contain these value types:Examples
Simple event — no properties:Event naming conventions
Use lowercase words separated by underscores:Built-in features
Auto-deduplication: If you accidentally calltrack() twice with the exact same event name and properties within 300ms, the second call is silently ignored. This prevents double-counting.
Auto-queue: If track() is called before init() runs, the event is queued in memory and sent automatically once init() is called.
Auto-retry: If the network request fails, the SDK retries once after 500ms.