Skip to content

Use capture-phase listeners for button click tracking - #1348

Merged
Jethro Nederhof (jethron) merged 1 commit into
snowplow:release/4.0.0from
jethron:button-plugin-capture
Oct 9, 2024
Merged

Use capture-phase listeners for button click tracking#1348
Jethro Nederhof (jethron) merged 1 commit into
snowplow:release/4.0.0from
jethron:button-plugin-capture

Conversation

@jethron

Copy link
Copy Markdown
Contributor

In v4 we switched the Form Tracking (#1329) and Link Click Tracking (#1325) plugins to using capture-phase event listeners instead of bubble-phase.

This makes the same change for the Button Click Tracking plugin to make it consistent.

This has caused issues for some clients historically, e.g. BCPF-1421 where pages stopping propagation of event bubbling prevented buttons being tracked.

@bundlemon

bundlemon Bot commented Oct 4, 2024

Copy link
Copy Markdown

BundleMon

Files added (6)
Status Path Size Limits
trackers/javascript-tracker/dist/sp.js
+24.25KB 30KB / +10%
libraries/browser-tracker-core/dist/index.mod
ule.js
+23.41KB 25KB / +10%
libraries/tracker-core/dist/index.module.js
+19.12KB 20KB / +10%
trackers/browser-tracker/dist/index.umd.min.j
s
+17.24KB 20KB / +10%
trackers/javascript-tracker/dist/sp.lite.js
+17.18KB 20KB / +10%
trackers/browser-tracker/dist/index.module.js
+3.49KB 5KB / +10%

Total files change +104.68KB 0%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

LGTM!

@jethron
Jethro Nederhof (jethron) merged commit d888e38 into snowplow:release/4.0.0 Oct 9, 2024
@jethron
Jethro Nederhof (jethron) deleted the button-plugin-capture branch October 9, 2024 22:17
Matus Tomlein (matus-tomlein) pushed a commit that referenced this pull request Oct 25, 2024
In v4 we switched the Form Tracking (#1329) and Link Click Tracking (#1325) plugins to using capture-phase event listeners instead of bubble-phase.

This makes the same change for the Button Click Tracking plugin to make it consistent.

This has caused issues for some clients historically, e.g. BCPF-1421 where pages stopping propagation of event bubbling prevented buttons being tracked.
Matus Tomlein (matus-tomlein) pushed a commit that referenced this pull request Oct 28, 2024
In v4 we switched the Form Tracking (#1329) and Link Click Tracking (#1325) plugins to using capture-phase event listeners instead of bubble-phase.

This makes the same change for the Button Click Tracking plugin to make it consistent.

This has caused issues for some clients historically, e.g. BCPF-1421 where pages stopping propagation of event bubbling prevented buttons being tracked.
Matus Tomlein (matus-tomlein) pushed a commit that referenced this pull request Oct 28, 2024
In v4 we switched the Form Tracking (#1329) and Link Click Tracking (#1325) plugins to using capture-phase event listeners instead of bubble-phase.

This makes the same change for the Button Click Tracking plugin to make it consistent.

This has caused issues for some clients historically, e.g. BCPF-1421 where pages stopping propagation of event bubbling prevented buttons being tracked.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants