Skip to content

Commit

Permalink
Fix complaining about timeout and interval types
Browse files Browse the repository at this point in the history
  • Loading branch information
robbie-c committed Aug 23, 2024
1 parent 8b88533 commit 3b86ec6
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/extensions/web-vitals/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ export class WebVitalsAutocapture {
private _initialized = false

private buffer: WebVitalsEventBuffer = { url: undefined, metrics: [], firstMetricTimestamp: undefined }
private _delayedFlushTimer: number | undefined
private _delayedFlushTimer: ReturnType<typeof setTimeout> | undefined

constructor(private readonly instance: PostHog) {
this._enabledServerSide = !!this.instance.persistence?.props[WEB_VITALS_ENABLED_SERVER_SIDE]
Expand Down
2 changes: 1 addition & 1 deletion src/heatmaps.ts
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ export class Heatmaps {

// TODO: Periodically flush this if no other event has taken care of it
private buffer: HeatmapEventBuffer
private _flushInterval: number | null = null
private _flushInterval: ReturnType<typeof setInterval> | null = null

constructor(instance: PostHog) {
this.instance = instance
Expand Down

0 comments on commit 3b86ec6

Please sign in to comment.