[wp-trac] [WordPress Trac] #35658: Provide additional data for registered meta through register_meta()

WordPress Trac noreply at wordpress.org
Wed Jun 29 20:19:24 UTC 2016


#35658: Provide additional data for registered meta through register_meta()
-------------------------------------------------+-------------------------
 Reporter:  jeremyfelt                           |       Owner:  jeremyfelt
     Type:  enhancement                          |      Status:  assigned
 Priority:  normal                               |   Milestone:  4.6
Component:  Options, Meta APIs                   |     Version:
 Severity:  normal                               |  Resolution:
 Keywords:  needs-unit-tests needs-testing has-  |     Focuses:
  patch rest-api                                 |
-------------------------------------------------+-------------------------

Comment (by helen):

 I've been dumping patches on here for sharing / checking out direction -
 they are unlikely to work in any sort of real way as-is.

 In any case, here is what I see as being important for a first run based
 on the many discussions I had at WCEU:

 * Enable REST API to start building out meta endpoints.
 * Set a direction for a Fields API to build out on top of.
 * Guide developers toward intended usage (related to below).
 * Defend as-yet-undecided core directions and focus on forward-compat.

 In my PoC patch, args are whitelisted using a filter. This is so that core
 can say "new ones will probably be added later and may conflict with
 custom stuff you add right now", but still give devs flexibility if they
 look in core code and are deliberate about what they're doing (essentially
 saying "yes, I acknowledge that I am voiding any back-compat warranty").
 Reaching directly into the global is also voiding the warranty :)

 As for the subtype stuff - I don't think we really need to enforce it for
 posts, but if we decide to do so in core for now, let's also hook it on
 like the args whitelist.

--
Ticket URL: <https://core.trac.wordpress.org/ticket/35658#comment:71>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list