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

use new metric helpers #185

Merged
merged 2 commits into from
Feb 15, 2024
Merged

use new metric helpers #185

merged 2 commits into from
Feb 15, 2024

Conversation

wsbrunson
Copy link
Member

  • use the new metricCounter interface
  • move one of the metrics outside of an if statement that doesn't apply to the metric
  • add base metric namespace for ppcp and the dimensions for v5 web.
  • add deprecated comment to sendMetricCount

@wsbrunson wsbrunson requested a review from a team as a code owner February 15, 2024 17:04
Copy link

codecov bot commented Feb 15, 2024

Codecov Report

Attention: 4 lines in your changes are missing coverage. Please review.

Comparison is base (c1b139a) 69.92% compared to head (be99235) 71.37%.

Files Patch % Lines
src/tracking.js 80.95% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #185      +/-   ##
==========================================
+ Coverage   69.92%   71.37%   +1.45%     
==========================================
  Files          22       22              
  Lines        1862     1869       +7     
  Branches      221      227       +6     
==========================================
+ Hits         1302     1334      +32     
+ Misses        550      525      -25     
  Partials       10       10              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Contributor

@jshawl jshawl left a comment

Choose a reason for hiding this comment

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

Looks good! one non-blocking comment 🚀

@@ -181,20 +183,6 @@ export function setupLogger() {
// token: getTokenType(),
// },
// })
// $FlowIssue
Copy link
Contributor

Choose a reason for hiding this comment

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

type safety ++ !

src/logger.js Outdated
});
});

// Deprecated - will remove once we have verified no other clients are importing this function
Copy link
Contributor

@jshawl jshawl Feb 15, 2024

Choose a reason for hiding this comment

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

option to use jsdoc syntax:

/** 
 * @deprecated - will remove...
 */

and then the message will show on hover in other code bases.

Copy link
Member Author

Choose a reason for hiding this comment

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

oh wow great idea!

@wsbrunson wsbrunson merged commit 9da22a4 into main Feb 15, 2024
5 checks passed
@wsbrunson wsbrunson deleted the move-metrics-interface branch February 15, 2024 22:21
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.

2 participants