Commit 8b719f45 by Chris

docs: update new method documentation

parent b31c5b6b
...@@ -66,9 +66,18 @@ The above markup would send the following event data when clicked: ...@@ -66,9 +66,18 @@ The above markup would send the following event data when clicked:
| Field | Value | | Field | Value |
| --------------- | -------------- | | --------------- | -------------- |
| `eventCategory` | `home` | | `eventCategory` | `home` |
| `eventAction` | `register cta` | | `eventAction` | `register cta` |
| `eventLabel` | `null` | | `eventLabel` | `null` |
GA4 event tracking is also supported, example:
| `data-track` value | `category` | `action` | `label` |
|:--------------------------------------|:----------------|:---------------|:---------------------|
| `"nav;click;new page"` | `nav` | `click` | `new page` |
| `"form;submit;contact us"` | `form` | `submit` | `contact us` |
| `"button;click;download brochure"` | `button` | `click` | `download brochure` |
| `"play video"` | *(none)* | `play video` | *(none)* |
--- ---
...@@ -169,4 +178,12 @@ Parameters: ...@@ -169,4 +178,12 @@ Parameters:
--- ---
#### `sendPageView(pagePath: string)`
Manually send a page_view event to Google Analytics 4.
Parameters:
* `pagePath: string` (optional) — The path of the page to report. Defaults to the current location pathname.
---
Copyright © 2018 FOREFRONT International Sdn Bhd. Copyright © 2018 FOREFRONT International Sdn Bhd.
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment