[wp-trac] [WordPress Trac] #31701: Emoji: Avoid enqueueing JS by default

WordPress Trac noreply at wordpress.org
Sat Mar 21 10:00:47 UTC 2015


#31701: Emoji: Avoid enqueueing JS by default
-----------------------------+--------------------------------------
 Reporter:  obenland         |       Owner:
     Type:  defect (bug)     |      Status:  new
 Priority:  normal           |   Milestone:  4.2
Component:  General          |     Version:  trunk
 Severity:  major            |  Resolution:
 Keywords:  emoji has-patch  |     Focuses:  javascript, performance
-----------------------------+--------------------------------------

Comment (by pento):

 [attachment:31701.4.diff] does some magic.

 * The emoji loader JS is moved to `wp-emoji-loader.js`, though is still
 embedded in the header thanks to the magic of `readfile()`. This means
 that...
 * `wp-emoji-loader.js` is minified as part of the build process, so will
 be embedded as a minified version on release (927 bytes, for reference).
 * `wp-emoji.js` and `twemoji.js` are concat'ed as part of the build
 process, into `wp-emoji-release.min.js`. I'm not wild about the name,
 suggestions are welcome. :-)

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


More information about the wp-trac mailing list