[wp-trac] [WordPress Trac] #27355: Customizer: Add framework for selective refresh (partial preview refreshes)

WordPress Trac noreply at wordpress.org
Sun Jan 31 07:13:00 UTC 2016


#27355: Customizer: Add framework for selective refresh (partial preview refreshes)
----------------------------+--------------------------
 Reporter:  westonruter     |       Owner:  westonruter
     Type:  task (blessed)  |      Status:  assigned
 Priority:  normal          |   Milestone:  4.5
Component:  Customize       |     Version:  3.4
 Severity:  normal          |  Resolution:
 Keywords:  needs-patch     |     Focuses:  javascript
----------------------------+--------------------------

Comment (by westonruter):

 Here's the latest work done to introduce the “Partial” construct to the
 Customizer APIs: https://github.com/xwp/wp-customize-partial-
 refresh/pull/18

 Introduced are `WP_Customize_Partial` PHP class and a corresponding
 `wp.customize.Partial` in JS. Partials are registered in PHP via
 (eventually) `$wp_customize->add_partial()` and in JS via
 `wp.customize.partial.create()`.

 One interesting bit is how to standardize handling the JS-initialization
 of any dynamic content, such as Emojis or MediaElement.js players. It will
 presently copy some of the logic developed for Jetpack's Infinite Scroll,
 but it would be great of there was a standard event that JS could listen
 for to make the necessary DOM changes (adding events, replacing elements,
 etc), similar to the `widget-added` and `widget-updated` events that are
 triggered on `document`.

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


More information about the wp-trac mailing list