Plugin does ignore jQuery dependency
-
In selection-sharer.php the script get’s added with
wp_enqueue_script( 'selection-sharer-js', plugins_url('/js/selection-sharer.js', __FILE__), false, '0.1');
But it has jQuery as a dependency so it should be
wp_enqueue_script( 'selection-sharer-js', plugins_url('/js/selection-sharer.js', __FILE__), array('jquery'), '0.1');
Also, the init script does get added right after and ignores the jQuery dependency. In my case this lead to the line being added before jQuery was loaded. An undefined error was thrown. I managed to modify the plugin to make it work in my case but this should really be fixed.
Viewing 2 replies - 1 through 2 (of 2 total)
Viewing 2 replies - 1 through 2 (of 2 total)
- The topic ‘Plugin does ignore jQuery dependency’ is closed to new replies.