All the information you need you can get from the global variable $wp_scripts
:
Code:
function wpse124227_wp_script_styles_debug_basic() {
global $wp_scripts, $wp_styles;
echo '<pre>';
//Scripts
print_r( $wp_scripts );
//Styles
//print_r( $wp_styles );
echo '</pre>';
}
add_filter( 'wp_head', 'wpse124227_wp_script_styles_debug_basic' );
To get a more specific output you have to define what you are looking for, instead of printing the whole object. Below linked information should get you started on that.
Information:
- How do I get the $handle for all enqueued scripts?
- Debug enqueued Scripts and Styles in WordPress
- Add a script as a dependency to a registered script
Update:
I just remembered there is a add-on to the Debug Bar plugin, called
Debug Bar List Script & Style Dependencies
, which does show scipts and styles dependencies and orders them. But I don’t know how the add-on does it, never looked at the code, and if that’s exactly what you want. You’d have to inspect that yourself.