How to enqueue every script in a folder automatically?
There’s nothing wrong with enqueuing many files by using wp_enqueue_script. If you are referring to it as frustrating, then there is a simple solution for this. PHP offers a function that can list files and directories. By using glob you can list every .js file in your directory, and then enqueue them by a loop. … Read more