Skip to content
GitLab
  • Explore
  • Sign in
  • Davide Ciacco
  • Web Analytics Web Lib Example
  • Wiki
  • Home
  • Events
  • Events configuration
  • Events Configuration File

Events Configuration File · Changes

Page history
Update Events Configuration File authored Apr 26, 2021 by Davide Ciacco's avatar Davide Ciacco
Hide whitespace changes
Inline Side-by-side
home/events/events-configuration/Events-Configuration-File.md
View page @ 8574fa24
......@@ -12,4 +12,17 @@ The events can be defined inside a configuration file structured like this:
];
})();
```
\ No newline at end of file
```
## Event object structure
```typescript
{
urls: string[], // the URLs on the pages on which the event will be used in (accepts the `*` wildcard, for example `["https://domain.com/*"]` will make the event available on every page of _domain.com_)
type: eventType, // like `eventTypes.onPage`
eventId: string', // the event identifier
categories: string[], // any number of categories can be added to an event
selector: string, // CSS selector
verifyCallback?: () => boolean, // event verification function, if it returns `false` the event will not be sent
},
```
Clone repository
  • home
    • events
      • events configuration
        • Events Configuration File
        • Send Event Method