Commit 0b3b8a6
authored
jsx: Remove unnecessary hasOwnProperty check (#28775)
Follow up to #28768.
The modern JSX runtime (`jsx`) does not need to check if each prop is a
direct property with `hasOwnProperty` because the compiler always passes
a plain object.
I'll leave the check in the old JSX runtime (`createElement`) since that
one can be called manually with any kind of object, and if there were
old user code that relied on this for some reason, it would be using
that runtime.1 parent e63918d commit 0b3b8a6
1 file changed
+4
-12
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
364 | 364 | | |
365 | 365 | | |
366 | 366 | | |
367 | | - | |
368 | | - | |
369 | | - | |
370 | | - | |
371 | | - | |
372 | | - | |
| 367 | + | |
| 368 | + | |
373 | 369 | | |
374 | 370 | | |
375 | 371 | | |
| |||
603 | 599 | | |
604 | 600 | | |
605 | 601 | | |
606 | | - | |
607 | | - | |
608 | | - | |
609 | | - | |
610 | | - | |
611 | | - | |
| 602 | + | |
| 603 | + | |
612 | 604 | | |
613 | 605 | | |
614 | 606 | | |
| |||
0 commit comments