[wp-trac] [WordPress Trac] #59453: Replace property_exists call in block api with instanceof
WordPress Trac
noreply at wordpress.org
Tue Sep 26 16:00:43 UTC 2023
#59453: Replace property_exists call in block api with instanceof
--------------------------+-------------------------------
Reporter: spacedmonkey | Owner: gziolo
Type: enhancement | Status: reviewing
Priority: normal | Milestone: Future Release
Component: Editor | Version: 5.8
Severity: normal | Resolution:
Keywords: has-patch | Focuses: coding-standards
--------------------------+-------------------------------
Comment (by gziolo):
I'm not entirely sure how backporting works for these files, but it's
worth emphasizing that the same code lives in the Gutenberg plugin in
https://github.com/WordPress/gutenberg/tree/trunk/lib/block-supports. I'm
sure these files aren't copied automatically, but if you agree on the
changes, we will have to apply the same set of changes in the Gutenberg
plugin. I can see how these changes would improve performance by using
language constructs like `instanceof ` and `isset`.
A separate discussion would be how to make it easier to sync code between
WordPress core and Gutenberg for block supports.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/59453#comment:5>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list