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 @ 8bdd2002
......@@ -17,12 +17,12 @@ The events can be defined inside a configuration file structured like this:
## Event object structure
```typescript
type Event = {
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
eventStructure = {
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
}
```
\ No newline at end of file
Clone repository
  • home
    • events
      • events configuration
        • Events Configuration File
        • Send Event Method