mirror of
https://github.com/kremalicious/portfolio.git
synced 2024-12-22 09:13:19 +01:00
window.umami typing
This commit is contained in:
parent
2de52ab1bd
commit
cfd6858f6e
32
src/@types/matomo.d.ts
vendored
32
src/@types/matomo.d.ts
vendored
@ -1,32 +0,0 @@
|
||||
interface Dimensions {
|
||||
dimension1?: string
|
||||
dimension2?: string
|
||||
dimension3?: string
|
||||
dimension4?: string
|
||||
dimension5?: string
|
||||
dimension6?: string
|
||||
dimension7?: string
|
||||
dimension8?: string
|
||||
dimension9?: string
|
||||
dimension10?: string
|
||||
}
|
||||
|
||||
declare global {
|
||||
interface Window {
|
||||
_paq?:
|
||||
| (
|
||||
| Dimensions
|
||||
| number[]
|
||||
| string[]
|
||||
| number
|
||||
| string
|
||||
| null
|
||||
| undefined
|
||||
)[][]
|
||||
| null
|
||||
}
|
||||
}
|
||||
|
||||
window._paq = window._paq || {}
|
||||
|
||||
export {}
|
17
src/@types/umami.d.ts
vendored
Normal file
17
src/@types/umami.d.ts
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
declare global {
|
||||
interface Window {
|
||||
umami?: (eventName: string) => void | {
|
||||
trackEvent: (
|
||||
event_name: string,
|
||||
event_data?: { [key: string]: string },
|
||||
url?: string,
|
||||
website_id?: string
|
||||
) => void
|
||||
trackView: (url: string, referrer?: string, website_id?: string) => void
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
window.umami = window.umami || {}
|
||||
|
||||
export {}
|
Loading…
Reference in New Issue
Block a user