Skip to content

Update uuid package dependency to version 10.0.0 (close #1305) - #1357

Merged
Matus Tomlein (matus-tomlein) merged 2 commits into
release/4.0.0from
issue/update_uuid_v9
Oct 21, 2024
Merged

Update uuid package dependency to version 10.0.0 (close #1305)#1357
Matus Tomlein (matus-tomlein) merged 2 commits into
release/4.0.0from
issue/update_uuid_v9

Conversation

@matus-tomlein

@matus-tomlein Matus Tomlein (matus-tomlein) commented Oct 18, 2024

Copy link
Copy Markdown
Contributor

This PR further updates the uuid package used by the tracker from v7 to v9 (edit: v10). The reason for this is the performance improvements that they introduced:

  1. optimize uuid.v1 by 1.3x uuid.v4 by 4.3x (430%) (chore: optimize uuid.v4 by 4.3x (430%) (internal stringify by 33x) uuidjs/uuid#597) (3a033f6)
  2. use native crypto.randomUUID when available (feat: use native crypto.randomUUID when available uuidjs/uuid#600) (c9e076c)

This uuid version drops support for older Node and browser versions:

  • Drop Node.js 10.x support (edit: upgrading to 10 also drops support for Node 14)
  • Drop IE 11 and Safari 10 support. Drop support for browsers that don't correctly implement const/let and default arguments, and no longer transpile the browser build to ES2015.

There already is version 11 of the uuid package, but that further drops browser and node support (already dropped 14), which I am not sure if we should do.

Edit: On second thought, we basically dropped support for Node <18 by using fetch, so I think it's safe upgrade the uuid library to 10. Also the bug fixes seem important, so seems sensible to do.

@bundlemon

bundlemon Bot commented Oct 18, 2024

Copy link
Copy Markdown

BundleMon

Files added (6)
Status Path Size Limits
trackers/javascript-tracker/dist/sp.js
+24.27KB 30KB / +10%
libraries/browser-tracker-core/dist/index.mod
ule.js
+23.45KB 25KB / +10%
libraries/tracker-core/dist/index.module.js
+19.18KB 20KB / +10%
trackers/browser-tracker/dist/index.umd.min.j
s
+17.21KB 20KB / +10%
trackers/javascript-tracker/dist/sp.lite.js
+17.14KB 20KB / +10%
trackers/browser-tracker/dist/index.module.js
+3.49KB 5KB / +10%

Total files change +104.74KB 0%

Final result: ✅

View report in BundleMon website ➡️


Current branch size history

@matus-tomlein Matus Tomlein (matus-tomlein) changed the title Update uuid package dependency to version 9.0.1 (close #1305) Update uuid package dependency to version 10.0.0 (close #1305) Oct 18, 2024

@greg-el Greg Leonard (greg-el) left a comment

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

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