Opened 2 years ago
Closed 2 years ago
#60742 closed defect (bug) (fixed)
Script Modules: Module src not filterable.
| Reported by: |
|
Owned by: |
|
|---|---|---|---|
| Milestone: | 6.5 | Priority: | normal |
| Severity: | normal | Version: | 6.5 |
| Component: | Script Loader | Keywords: | has-patch commit dev-reviewed fixed-major |
| Focuses: | Cc: |
Description
The new Script Modules feature doesn't allow the URL being imported to be filtered, this means that it's not possible for plugins to either filter it to load from a CDN, or add/alter params (Such as we do on WordPress.org for cache issues).
At a minimum WP_Script_Modules::get_versioned_src() should have a filter, ideally it could re-use the script_loader_src filter for maximum compatibility with existing script-related filters, but it could use something specific like script_module_src if required for some reason.
Change History (8)
This ticket was mentioned in PR #6243 on WordPress/wordpress-develop by @dd32.
2 years ago
#1
- Keywords has-patch added
@swissspidy commented on PR #6243:
2 years ago
#6
Committed in https://core.trac.wordpress.org/changeset/57840
Note: See
TracTickets for help on using
tickets.
Trac ticket: https://core.trac.wordpress.org/ticket/60742
See https://github.com/WordPress/wporg-mu-plugins/issues/587