Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: should use event listener #1701

Merged
merged 1 commit into from
Jan 29, 2025
Merged

fix: should use event listener #1701

merged 1 commit into from
Jan 29, 2025

Conversation

pauldambra
Copy link
Member

or else the pnpm complains

@pauldambra pauldambra requested a review from a team as a code owner January 29, 2025 16:06
Copy link

vercel bot commented Jan 29, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
posthog-js ✅ Ready (Inspect) Visit Preview Jan 29, 2025 4:10pm

@pauldambra pauldambra requested review from rafaeelaudibert and removed request for a team January 29, 2025 16:07
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Summary

Modified event listener implementation in surveys component to use a custom addEventListener utility instead of direct window event listeners, addressing pnpm build/lint issues.

  • Changed window.addEventListener to custom addEventListener utility in src/extensions/surveys.tsx for URL change events
  • Added cleanup of event listeners in component unmount
  • Maintains same event handling functionality while resolving pnpm compatibility concerns
  • Ensures consistent event listener behavior across different environments

1 file(s) reviewed, no comment(s)
Edit PR Review Bot Settings | Greptile

Copy link

Size Change: -224 B (-0.01%)

Total Size: 3.28 MB

Filename Size Change
dist/all-external-dependencies.js 215 kB -28 B (-0.01%)
dist/array.full.es5.js 266 kB -28 B (-0.01%)
dist/array.full.js 369 kB -28 B (-0.01%)
dist/array.full.no-external.js 368 kB -28 B (-0.01%)
dist/module.full.js 369 kB -28 B (-0.01%)
dist/module.full.no-external.js 368 kB -28 B (-0.01%)
dist/surveys-preview.js 68.8 kB -28 B (-0.04%)
dist/surveys.js 71.8 kB -28 B (-0.04%)
ℹ️ View Unchanged
Filename Size
dist/array.js 181 kB
dist/array.no-external.js 180 kB
dist/customizations.full.js 13.8 kB
dist/dead-clicks-autocapture.js 14.5 kB
dist/exception-autocapture.js 9.48 kB
dist/external-scripts-loader.js 2.64 kB
dist/main.js 182 kB
dist/module.js 181 kB
dist/module.no-external.js 180 kB
dist/recorder-v2.js 115 kB
dist/recorder.js 115 kB
dist/tracing-headers.js 1.76 kB
dist/web-vitals.js 10.4 kB

compressed-size-action

@pauldambra pauldambra requested review from a team January 29, 2025 16:18
Copy link
Member

@rafaeelaudibert rafaeelaudibert left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ahn, is this new code? It must've been commited after I started my branch or else my code would've gotten it

@rafaeelaudibert rafaeelaudibert added the bump patch Bump patch version when this PR gets merged label Jan 29, 2025
@pauldambra pauldambra removed the bump patch Bump patch version when this PR gets merged label Jan 29, 2025
@pauldambra pauldambra merged commit 17ad70a into main Jan 29, 2025
32 checks passed
@pauldambra pauldambra deleted the fix/evntlistnr branch January 29, 2025 16:21
@lucasheriques
Copy link
Contributor

learned something new today 🤔

@rafaeelaudibert yup it's my code, merged on a PR yesterday

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants