[wp-trac] [WordPress Trac] #43781: adding apply_filters on $handle in localize
WordPress Trac
noreply at wordpress.org
Mon Apr 16 14:26:34 UTC 2018
#43781: adding apply_filters on $handle in localize
---------------------------+-----------------------------
Reporter: DuckDagobert | Owner: (none)
Type: enhancement | Status: new
Priority: normal | Milestone: Awaiting Review
Component: Script Loader | Version: 4.9.5
Severity: normal | Keywords:
Focuses: |
---------------------------+-----------------------------
in functions.wp-scripts.php we have:
return $wp_scripts->localize( $handle, $object_name, $l10n );
it would be nice to have an apply_filters on the $handle (with object_name
as an argument optionally), since it would make overwriting it e.g. for a
global concat minified file much easier & faster.
(bc now I have to get the scripts, then loop over it, localize the
group,...) while I could do the whole thing with an apply_filters within 1
line.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/43781>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list