[wp-trac] [WordPress Trac] #35630: oEmed Link Handling Can't Be Refired

WordPress Trac noreply at wordpress.org
Fri Jan 29 08:40:34 UTC 2016


#35630: oEmed Link Handling Can't Be Refired
--------------------------+-----------------------------
 Reporter:  JamesDiGioia  |       Owner:  swissspidy
     Type:  enhancement   |      Status:  assigned
 Priority:  normal        |   Milestone:  Future Release
Component:  Embeds        |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |     Focuses:
--------------------------+-----------------------------
Changes (by swissspidy):

 * keywords:   => needs-patch
 * owner:   => swissspidy
 * status:  new => assigned
 * milestone:  Awaiting Review => Future Release


Comment:

 Thanks for your report. Supporting lazy-loaded content sounds like
 something we should support automatically.

 We're currently using


 {{{
 var links = document.getElementsByTagName( 'a' );
 for ( i = 0; i < links.length; i++ ) {
         links[ i ].addEventListener( 'click', linkClickHandler );
 }
 }}}

 whereas we might just use something like

 {{{
 document.addEventListener( 'click', 'linkClickHandler' );
 }}}

 This would require/allow us to to simplify the logic inside
 `linkClickHandler()`.

 If this is already enough, we could look into making things available
 under the `wp` namespace at a later point, e.g. functions like
 `wp.embed.send_some_stuff()`.

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


More information about the wp-trac mailing list