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

Match numbers and string to element-valued properties #6028

Merged
merged 1 commit into from
Jul 1, 2024

Conversation

bkrmendy
Copy link
Contributor

@bkrmendy bkrmendy commented Jul 1, 2024

Problem

If there's no annotation for a component property, we only treat JSX elements as matching values for render props, even though strings and numbers would be valid elements children as well.

Fix

If we detect a render prop, the matching code treats strings and numbers as matching as well.

#5979

Copy link
Contributor

github-actions bot commented Jul 1, 2024

Try me

Copy link

relativeci bot commented Jul 1, 2024

#13216 Bundle Size — 62.37MiB (~+0.01%).

01f8a0e(current) vs 6339ece master#13214(baseline)

Warning

Bundle contains 51 duplicate packages – View duplicate packages

Bundle metrics  Change 2 changes Regression 1 regression
                 Current
#13216
     Baseline
#13214
Regression  Initial JS 45.43MiB(~+0.01%) 45.43MiB
No change  Initial CSS 0B 0B
Change  Cache Invalidation 21.58% 23.23%
No change  Chunks 30 30
No change  Assets 33 33
No change  Modules 4313 4313
No change  Duplicate Modules 525 525
No change  Duplicate Code 31.79% 31.79%
No change  Packages 450 450
No change  Duplicate Packages 51 51
Bundle size by type  Change 2 changes Regression 1 regression Improvement 1 improvement
                 Current
#13216
     Baseline
#13214
Regression  JS 62.35MiB (~+0.01%) 62.35MiB
Improvement  HTML 11.16KiB (-0.33%) 11.2KiB

Bundle analysis reportBranch feature/jsx-match-string-numberProject dashboard

@bkrmendy bkrmendy marked this pull request as ready for review July 1, 2024 10:29
@bkrmendy bkrmendy linked an issue Jul 1, 2024 that may be closed by this pull request
@bkrmendy bkrmendy merged commit 6a26bbc into master Jul 1, 2024
17 checks passed
@bkrmendy bkrmendy deleted the feature/jsx-match-string-number branch July 1, 2024 10:51
liady pushed a commit that referenced this pull request Dec 13, 2024
## Problem
If there's no annotation for a component property, we only treat JSX
elements as matching values for render props, even though strings and
numbers would be valid elements children as well.

## Fix
If we detect a render prop, the matching code treats strings and numbers
as matching as well.

#5979
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.

Data picker bug: overly strict type filtering
3 participants