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

My Jetpack: Fire Tracks event when clicking CTA button on product Interstitial page #22672

Merged
merged 3 commits into from
Feb 4, 2022

Conversation

oskosk
Copy link
Contributor

@oskosk oskosk commented Feb 4, 2022

Adds tracking for click on product interstitial pages CTA buttons

Changes proposed in this Pull Request:

  • Introduces firing of jetpack_myjetpack_product_interstitial_add_link_click.

Jetpack product discussion

Does this pull request change what data or activity we track or use?

Introduces 1 new event:

  • jetpack_myjetpack_product_interstitial_add_link_click fired when the user clicks the interstitial page add button

Testing instructions:

  • Checkout this branch on a site with Jetpack connected the Backup plugin active, and the JETPACK_ENABLE_MY_JETPACK constant set to true.
  • Open the browser and visit the site's wp-admin.
  • Open the developer console, execute the following code: localStorage.debug='dops:analyitics*
  • Go to this patch wp-admin/admin.php?page=my-jetpack#/add-boost.
  • Click the Add... button
  • Confirm that the developer console displays the events jetpack_myjetpack_product_interstitial_add_link_click

@oskosk oskosk added [Status] Needs Review To request a review from fellow Jetpack developers. Label will be renamed soon. [Feature] Tracks [Package] My Jetpack labels Feb 4, 2022
@oskosk oskosk added this to the My Jetpack MVP milestone Feb 4, 2022
@oskosk oskosk requested a review from a team February 4, 2022 14:00
@github-actions
Copy link
Contributor

github-actions bot commented Feb 4, 2022

Thank you for your PR!

When contributing to Jetpack, we have a few suggestions that can help us test and review your patch:

  • ✅ Include a description of your PR changes.
  • ✅ All commits were linted before commit.
  • ✅ Add a "[Status]" label (In Progress, Needs Team Review, ...).
  • ✅ Add testing instructions.
  • ✅ Specify whether this PR includes any changes to data or privacy.
  • ✅ Add changelog entries to affected projects

This comment will be updated as you work on your PR and make changes. If you think that some of those checks are not needed for your PR, please explain why you think so. Thanks for cooperation 🤖


The e2e test report can be found here. Please note that it can take a few minutes after the e2e tests checks are complete for the report to be available.


Once your PR is ready for review, check one last time that all required checks (other than "Required review") appearing at the bottom of this PR are passing or skipped.
Then, add the "[Status] Needs Team review" label and ask someone from your team review the code.
Once you’ve done so, switch to the "[Status] Needs Review" label; someone from Jetpack Crew will then review this PR and merge it to be included in the next Jetpack release.

return (
<Container className={ styles.container } horizontalSpacing={ 0 } horizontalGap={ 0 }>
<Col sm={ 4 } md={ 4 } lg={ 5 }>
<ProductDetail slug={ slug } />
<ProductDetail slug={ slug } trackButtonClick={ trackProductClick } />
Copy link
Contributor

Choose a reason for hiding this comment

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

I think the event should be named onAdd(), or something like that. If you agree, we can rename it in a follow-up PR

Suggested change
<ProductDetail slug={ slug } trackButtonClick={ trackProductClick } />
<ProductDetail slug={ slug } onAdd={ trackProductClick } />

Copy link
Contributor

@retrofox retrofox left a comment

Choose a reason for hiding this comment

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

LGTM

image

@retrofox retrofox enabled auto-merge (squash) February 4, 2022 16:34
@retrofox retrofox added [Status] Ready to Merge Go ahead, you can push that green button! and removed [Status] Needs Review To request a review from fellow Jetpack developers. Label will be renamed soon. labels Feb 4, 2022
@retrofox retrofox merged commit d2bc493 into master Feb 4, 2022
@retrofox retrofox deleted the add/my-jetpack-tracks-event-interstitial-click branch February 4, 2022 16:34
@github-actions github-actions bot removed the [Status] Ready to Merge Go ahead, you can push that green button! label Feb 4, 2022
@oskosk oskosk mentioned this pull request Feb 8, 2022
47 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants