[wp-trac] [WordPress Trac] #60240: Script Modules API: Move the modules to the footer in classic themes

WordPress Trac noreply at wordpress.org
Wed Jan 24 10:38:11 UTC 2024


#60240: Script Modules API: Move the modules to the footer in classic themes
-------------------------------------------------+-------------------------
 Reporter:  luisherranz                          |       Owner:
                                                 |  youknowriad
     Type:  enhancement                          |      Status:  closed
 Priority:  normal                               |   Milestone:  Awaiting
                                                 |  Review
Component:  Script Loader                        |     Version:
 Severity:  major                                |  Resolution:  fixed
 Keywords:  has-patch has-unit-tests needs-      |     Focuses:  javascript
  testing-info                                   |
-------------------------------------------------+-------------------------
Changes (by youknowriad):

 * owner:  (none) => youknowriad
 * status:  new => closed
 * resolution:   => fixed


Comment:

 In [changeset:"57345" 57345]:
 {{{
 #!CommitTicketReference repository="" revision="57345"
 Script Loader: Load the modules to the footer in classic themes

 Incremental import maps fail if the import map is printed after the module
 scripts.
 This means, we should always render import maps first. This means that for
 classic themes, we need to move the import map and modules to the footer
 because we can't know before that which modules are needed.

 Props luisherranz, cbravobernal.
 Fixes #60240.
 }}}

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


More information about the wp-trac mailing list