Skip to content

Add screen tracking plugin and add support for browser plugins - #1394

Merged
Matus Tomlein (matus-tomlein) merged 2 commits into
wip/react-nativefrom
issue/screen-tracking
Nov 29, 2024
Merged

Add screen tracking plugin and add support for browser plugins#1394
Matus Tomlein (matus-tomlein) merged 2 commits into
wip/react-nativefrom
issue/screen-tracking

Conversation

@matus-tomlein

Copy link
Copy Markdown
Contributor

This PR adds a new screen tracking plugin for tracking screen view events. The plugin has full support for screen engagement tracking which means it has the following functionality:

  1. Automatically tracks a screen_end event just before transitioning to a new screen view event.
  2. Attaches a screen_summary context entity to screen_end, application_foreground and application_background events.

It also tracks the screen context entity with all events following a screen view and adds previousName and previousId references to screen view events.

The plugin is included in the React Native tracker. In order to make it compatible with the tracker, I had to add support for browser tracker plugins. By doing this, the tracker is now compatible also with our other browser plugins, such as the e-commerce plugin – I added unit tests for this.

@bundlemon

bundlemon Bot commented Nov 26, 2024

Copy link
Copy Markdown

BundleMon

Files added (6)
Status Path Size Limits
trackers/javascript-tracker/dist/sp.js
+24.54KB 30KB / +10%
libraries/browser-tracker-core/dist/index.mod
ule.js
+23.59KB 25KB / +10%
libraries/tracker-core/dist/index.module.js
+19.5KB 20KB / +10%
trackers/browser-tracker/dist/index.umd.min.j
s
+17.44KB 20KB / +10%
trackers/javascript-tracker/dist/sp.lite.js
+17.39KB 20KB / +10%
trackers/browser-tracker/dist/index.module.js
+3.49KB 5KB / +10%

Total files change +105.95KB 0%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

lgtm

Comment thread plugins/browser-plugin-screen-tracking/src/utils.ts Outdated
Comment thread plugins/browser-plugin-screen-tracking/src/api.ts Outdated
Comment thread plugins/browser-plugin-screen-tracking/src/api.ts
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