[wp-trac] [WordPress Trac] #56313: Add the ability to handle ES Modules and Import Maps
WordPress Trac
noreply at wordpress.org
Tue Jan 23 03:32:19 UTC 2024
#56313: Add the ability to handle ES Modules and Import Maps
-------------------------------------+-------------------------------------
Reporter: idad5 | Owner: luisherranz
Type: enhancement | Status: reopened
Priority: normal | Milestone: 6.5
Component: Script Loader | Version:
Severity: normal | Resolution:
Keywords: has-patch has-unit- | Focuses: javascript,
tests commit | performance
-------------------------------------+-------------------------------------
Comment (by dmsnell):
In [changeset:"57327" 57327]:
{{{
#!CommitTicketReference repository="" revision="57327"
Script Modules API: Rename `wp_module` to `wp_script_module`
Renames all mentions to "module" with "script module", including function
names, comments, and tests.
Follow up to [57269]
The list of functions renamed are:
- `wp_module()` -> `wp_script_module()`.
- `wp_register_module()` -> `wp_register_script_module()`.
- `wp_enqueue_module()` -> `wp_enqueue_script_module()`.
- `wp_dequeue_module()` -> `wp_dequeue_script_module()`.
- `WP_Script_Modules::print_enqueued_modules()` ->
`WP_Script_Modules::print_enqueued_script_modules()`.
- `WP_Script_Modules::print_module_preloads()` ->
`WP_Script_Modules::print_script_module_preloads()`.
It also adds PHP 7 typing to all the functions and improves the types of
the `$deps` argument of `wp_register_script_module()` and
`wp_enqueue_script_module()` using `@type`.
Props luisherranz, idad5, costdev, nefff, joemcgill, jorbin, swisspidy,
jonsurrel, flixos90, gziolo, westonruter, bernhard-reiter, kamranzafar4343
See #56313
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/56313#comment:63>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list