Skip to content

Instantly share code, notes, and snippets.

@selrond
Forked from davidkryzaniak/functions.php
Last active December 20, 2016 09:59
Show Gist options
  • Save selrond/b03755aa1a912c5edc191dd1bd543019 to your computer and use it in GitHub Desktop.
Save selrond/b03755aa1a912c5edc191dd1bd543019 to your computer and use it in GitHub Desktop.
<?php
// 'after_setup_theme', with 100, so it is the absolute last thing to load
add_action('after_setup_theme', 'customize_parent_includes', 100);
function customize_parent_includes() {
//again, set this to 100 so it is the last thing loaded
add_action('wp_enqueue_scripts', 'bootstrap_custom', 100);
}
//crap to remove
function bootstrap_custom()
{
//-------- dequeue here! --------
//dequeue the style:
wp_dequeue_style('font-awesome'); //'font-awesome' was enqueued in the parent. Dequeue it.
//dequeue the script:
wp_dequeue_script('hover-script'); //'hover-script' was enqueued in the parent. Dequeue it.
wp_dequeue_script('main-script'); //'main-script' was enqueued in the parent. Dequeue it.
}
@selrond
Copy link
Author

selrond commented Dec 20, 2016

@davidkryzaniak I've updated the (dequeued) enqueued file names for clarity. Feel free to change them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment