How to properly dequeue scripts and styles in child theme?

Posted by Prem Tiwari | Updated on

How to properly dequeue scripts and styles in child theme?

You are very nearer to the solution, because you are on the right path. Just to tweak a little bit. There are two such action hooks:

  • wp_print_scripts, and
  • wp_print_styles

So the way you can do it, is: hook ’em differently:

And the correct way is to deregister them beside dequeuing. So first dequeue them, and then deregister them accordingly.


If you like this question & answer and want to contribute, then write your question & answer and email to freewebmentor[@]gmail.com. Your question and answer will appear on FreeWebMentor.com and help other developers.

Related Questions & Answers