snowplow-javascript-tracker
snowplow-javascript-tracker copied to clipboard
Support JWPlayer in browser-plugin-media-tracking (closes #1116)
This PR adds a minimal set of changes to be able to support JWPlayer media. Additionally the JWPlayer media with poster functionality.
Notes
-
The check that has been added for the length of the detected media could be in some way enhanced with some
classnamesearch, but I do not think that it is required in this case. -
JWplayer adds the poster video on an additional 'second' video element, that is why we select the first which is the functional one.
-
Do you think we should create an exhaustive jwplayer check ?
-
There is an edge case for existing clients will see new events if they update to the latest version that we will publish. This edge case is described in the following scenario:
- A client has added media tracking.
- The client had targeted a container element with exactly two video elements.
- The tracking would not work and a console error would be shown continouusly until we publish this release.
- He updates to the latest version of the tracker. If all the above happen, he will start seeing some video events from the 'first' video element.
closes #1116
BundleMon
Files added (6)
| Status | Path | Size | Limits |
|---|---|---|---|
| :white_check_mark: | libraries/browser-tracker-core/dist/index.mod ule.js |
+23.8KB | 25KB / +10% |
| :white_check_mark: | trackers/javascript-tracker/dist/sp.js |
+23.49KB | 25KB / +10% |
| :white_check_mark: | trackers/javascript-tracker/dist/sp.lite.js |
+14.2KB | 15KB / +10% |
| :white_check_mark: | trackers/browser-tracker/dist/index.umd.min.j s |
+14.05KB | 15KB / +10% |
| :white_check_mark: | libraries/tracker-core/dist/index.module.js |
+13.35KB | 15KB / +10% |
| :white_check_mark: | trackers/browser-tracker/dist/index.module.js |
+3.46KB | 5KB / +10% |
Total files change +92.34KB 0%
Final result: :white_check_mark:
View report in BundleMon website ➡️