Outil de recherche WordPress pour les développeurs et auteurs de thèmes



pre_prepare_themes_for_js ›

Depuis4.2.0
Dépréciéen/a
apply_filters( 'pre_prepare_themes_for_js', array()
Paramètres: (3)
  • (array) $prepared_themes An associative array of theme data. Default empty array.
    Requis: Oui
  • (WP_Theme[]|null) $themes An array of theme objects to prepare, if any.
    Requis: Oui
  • (string) $current_theme The current theme slug.
    Requis: Oui
Défini(e) dans:
Codex:

Filters theme data before it is prepared for JavaScript.

Passing a non-empty array will result in wp_prepare_themes_for_js() returning early with that value instead.





Source

$prepared_themes = (array) apply_filters( 'pre_prepare_themes_for_js', array(), $themes, $current_theme );