Created
August 25, 2019 09:41
-
-
Save deeman/f49092997b6814d3433630838eb7b252 to your computer and use it in GitHub Desktop.
WordPress: How To Enquque script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //1. Add action | |
| add_action( 'wp_enqueue_scripts', 'my_enquque_script' ); | |
| //2. Set function | |
| //3. And Enquque | |
| function my_enquque_script() { | |
| wp_enqueue_script( 'my-script', get_stylesheet_directory_uri() . '/js/my_enquque_script.js', array( 'jquery' ), '1.0.0', true ); | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment