-
Notifications
You must be signed in to change notification settings - Fork 3
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: Add Event Timer module #154
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
FYI: you don’t need the !
in the PR title, unless you want to release a patch. feat
will do just fine for a minor update.
* @param {origin} [origin=page] - Either 'page' (default) or the name of the slot | ||
*/ | ||
trigger(eventName: string, origin = 'page'): void { | ||
const TRACKEDSLOTNAME = 'top-above-nav'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should this be extracted in a higher scope? It could be used in the triggers on lines 23 and 51.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can it be used on line 23?
Co-authored-by: Max Duval <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
would be great to have some unit tests on this, but i'm ok to move them on a subsequent PR
Adding the event timer module |
🎉 This PR is included in version 0.10.0 🎉 The release is available on: Your semantic-release bot 📦🚀 |
main failed on test coverage step: |
What does this change?
Adds an event timer module that can be imported and used globally.
Why?
As part of the performance OKR we need additional monitoring of performance.
Using this module gives us a single place to collate and handle events recorded for this