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

perf: optimize setting attributes #460

Closed
wants to merge 3 commits into from
Closed

Conversation

nolanlawson
Copy link
Owner

Very slight pref optimization, adds some complexity, but may be worth the tradeoff. Also avoids rendering useless empty attributes like aria-selected=''.

Copy link

github-actions bot commented Sep 20, 2024

📊 Tachometer Benchmark Results

Summary

benchmark-total

  • emoji-picker-element-change-tab: unsure 🔍 -7% - +4% (-2.49ms - +1.40ms)
    this-change vs tip-of-tree
  • emoji-picker-element-database-interactions: unsure 🔍 -3% - +4% (-3.54ms - +4.07ms)
    this-change vs tip-of-tree
  • emoji-picker-element-first-load: unsure 🔍 -3% - +6% (-1.66ms - +2.95ms)
    this-change vs tip-of-tree
  • emoji-picker-element-many-custom-emoji: unsure 🔍 -9% - +2% (-13.18ms - +3.21ms)
    this-change vs tip-of-tree
  • emoji-picker-element-second-load: unsure 🔍 -4% - +4% (-1.74ms - +1.82ms)
    this-change vs tip-of-tree

Results

emoji-picker-element-change-tab
VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
this-change
34.50ms - 37.08ms-unsure 🔍
-7% - +4%
-2.49ms - +1.40ms
tip-of-tree
tip-of-tree
34.88ms - 37.79msunsure 🔍
-4% - +7%
-1.40ms - +2.49ms
-
emoji-picker-element-database-interactions
VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
this-change
106.46ms - 112.11ms-unsure 🔍
-3% - +4%
-3.54ms - +4.07ms
tip-of-tree
tip-of-tree
106.47ms - 111.57msunsure 🔍
-4% - +3%
-4.07ms - +3.54ms
-
emoji-picker-element-first-load
VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
this-change
52.11ms - 55.37ms-unsure 🔍
-3% - +6%
-1.66ms - +2.95ms
tip-of-tree
tip-of-tree
51.47ms - 54.73msunsure 🔍
-5% - +3%
-2.95ms - +1.66ms
-
emoji-picker-element-many-custom-emoji
VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
this-change
127.77ms - 139.22ms-unsure 🔍
-9% - +2%
-13.18ms - +3.21ms
tip-of-tree
tip-of-tree
132.61ms - 144.35msunsure 🔍
-3% - +10%
-3.21ms - +13.18ms
-
emoji-picker-element-second-load
VersionAvg timevs this-change
vs tip-of-tree
tip-of-tree
this-change
43.73ms - 46.05ms-unsure 🔍
-4% - +4%
-1.74ms - +1.82ms
tip-of-tree
tip-of-tree
43.49ms - 46.20msunsure 🔍
-4% - +4%
-1.82ms - +1.74ms
-

tachometer-reporter-action v2 for Benchmarks

Copy link

github-actions bot commented Sep 20, 2024

Size Change: +154 B (+0.41%)

Total Size: 37.6 kB

Filename Size Change
./bundle.js 37.6 kB +154 B (+0.41%)

compressed-size-action

@nolanlawson
Copy link
Owner Author

The perf improvement is ~1% and the added complexity is high, so nah

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant