fix(react): silence invalid worklet warnings#2586
Conversation
🦋 Changeset detectedLatest commit: 041d9af The changes in this PR will be included in the next version bump. This PR includes changesets to release 2 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Merging this PR will degrade performance by 14.67%
|
| Benchmark | BASE |
HEAD |
Efficiency | |
|---|---|---|---|---|
| ⚡ | 002-hello-reactLynx-destroyBackground |
912.5 µs | 863.5 µs | +5.67% |
| ❌ | transform 1000 view elements |
40 ms | 46.9 ms | -14.67% |
Comparing Yradex:wt/remove-invalid-mtf-warn-20260509 (041d9af) with main (5b6a33d)2
Footnotes
-
26 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩
-
No successful run was found on
main(60a345b) during the generation of this report, so 5b6a33d was used instead as the comparison base. There might be some changes unrelated to this pull request in this report. ↩
React External#1065 Bundle Size — 690.27KiB (0%).041d9af(current) vs 60a345b main#1064(baseline) Bundle metrics
|
| Current #1065 |
Baseline #1064 |
|
|---|---|---|
0B |
0B |
|
0B |
0B |
|
0% |
0% |
|
0 |
0 |
|
3 |
3 |
|
17 |
17 |
|
5 |
5 |
|
8.59% |
8.59% |
|
0 |
0 |
|
0 |
0 |
Bundle analysis report Branch Yradex:wt/remove-invalid-mtf-war... Project dashboard
Generated by RelativeCI Documentation Report issue
React Example#7950 Bundle Size — 235.77KiB (0%).041d9af(current) vs 60a345b main#7948(baseline) Bundle metrics
|
| Current #7950 |
Baseline #7948 |
|
|---|---|---|
0B |
0B |
|
0B |
0B |
|
0% |
0% |
|
0 |
0 |
|
4 |
4 |
|
197 |
197 |
|
80 |
80 |
|
44.85% |
44.85% |
|
2 |
2 |
|
0 |
0 |
Bundle size by type no changes
| Current #7950 |
Baseline #7948 |
|
|---|---|---|
145.76KiB |
145.76KiB |
|
90.01KiB |
90.01KiB |
Bundle analysis report Branch Yradex:wt/remove-invalid-mtf-war... Project dashboard
Generated by RelativeCI Documentation Report issue
React Example with Element Template#215 Bundle Size — 198.02KiB (0%).041d9af(current) vs 60a345b main#214(baseline) Bundle metrics
Bundle size by type
|
| Current #215 |
Baseline #214 |
|
|---|---|---|
145.76KiB |
145.76KiB |
|
52.26KiB |
52.26KiB |
Bundle analysis report Branch Yradex:wt/remove-invalid-mtf-war... Project dashboard
Generated by RelativeCI Documentation Report issue
Web Explorer#9522 Bundle Size — 900.02KiB (0%).041d9af(current) vs 60a345b main#9521(baseline) Bundle metrics
Bundle size by type
|
| Current #9522 |
Baseline #9521 |
|
|---|---|---|
495.88KiB |
495.88KiB |
|
401.92KiB |
401.92KiB |
|
2.22KiB |
2.22KiB |
Bundle analysis report Branch Yradex:wt/remove-invalid-mtf-war... Project dashboard
Generated by RelativeCI Documentation Report issue
React MTF Example#1080 Bundle Size — 206.6KiB (-0.04%).041d9af(current) vs 60a345b main#1078(baseline) Bundle metrics
Bundle size by type
Bundle analysis report Branch Yradex:wt/remove-invalid-mtf-war... Project dashboard Generated by RelativeCI Documentation Report issue |
Summary by CodeRabbit
Bug Fixes
Overview
runWorkletcan receive invalid or missing main-thread function objects when optional/nullish handlers flow through the worklet event path.MainThreadFunction: Invalid function objectwarning.Key Points
_wkltIdor_lepusWorkletHashreturn without executing a worklet.JSON.stringify(ctx)work were removed from that early-return path.For example, an event value shaped like
{ _workletType: "main-thread" }is still treated as non-executable worklet ctx, but it is ignored silently instead of surfacing a developer-console warning.Checklist