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

feat: Added better sub logging utils #1581

Merged
merged 6 commits into from
Dec 6, 2024
Merged

feat: Added better sub logging utils #1581

merged 6 commits into from
Dec 6, 2024

Conversation

benjackwhite
Copy link
Collaborator

@benjackwhite benjackwhite commented Dec 5, 2024

Changes

Adds a createLogger function to help standardise some of our log patterns that includes the sub name

Also added a better helper as the various mocking things were a bit messy.

Checklist

  • Tests for new code (see advice on the tests we use)
  • Accounted for the impact of any changes across different browsers
  • Accounted for backwards compatibility of any changes (no breaking changes in posthog-js!)

Copy link

vercel bot commented Dec 5, 2024

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

Name Status Preview Updated (UTC)
posthog-js ✅ Ready (Inspect) Visit Preview Dec 6, 2024 8:29am

Copy link

github-actions bot commented Dec 5, 2024

Size Change: +1.09 kB (+0.03%)

Total Size: 3.2 MB

Filename Size Change
dist/all-external-dependencies.js 206 kB +171 B (+0.08%)
dist/array.full.es5.js 259 kB -23 B (-0.01%)
dist/array.full.js 362 kB +37 B (+0.01%)
dist/array.full.no-external.js 361 kB +4 B (0%)
dist/array.js 177 kB +104 B (+0.06%)
dist/array.no-external.js 175 kB -12 B (-0.01%)
dist/customizations.full.js 12.6 kB +69 B (+0.55%)
dist/dead-clicks-autocapture.js 14.4 kB +85 B (+0.6%)
dist/exception-autocapture.js 9.48 kB +112 B (+1.2%)
dist/external-scripts-loader.js 2.48 kB +113 B (+4.78%) 🔍
dist/main.js 177 kB +104 B (+0.06%)
dist/module.full.js 363 kB +37 B (+0.01%)
dist/module.full.no-external.js 361 kB +4 B (0%)
dist/module.js 177 kB +15 B (+0.01%)
dist/module.no-external.js 175 kB -20 B (-0.01%)
dist/recorder-v2.js 115 kB +98 B (+0.09%)
dist/recorder.js 115 kB +98 B (+0.09%)
dist/surveys.js 63.3 kB +97 B (+0.15%)
ℹ️ View Unchanged
Filename Size
dist/surveys-preview.js 57.6 kB
dist/tracing-headers.js 1.75 kB
dist/web-vitals.js 10.3 kB

compressed-size-action

Copy link
Member

@pauldambra pauldambra left a comment

Choose a reason for hiding this comment

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

nice

@benjackwhite benjackwhite marked this pull request as ready for review December 6, 2024 08:18
@benjackwhite benjackwhite added the bump patch Bump patch version when this PR gets merged label Dec 6, 2024
@benjackwhite benjackwhite merged commit a334cc3 into main Dec 6, 2024
16 checks passed
@benjackwhite benjackwhite deleted the feat/better-logger branch December 6, 2024 09:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bump patch Bump patch version when this PR gets merged
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants