Reply To: wp_enqueue_script issue on activity page
Did henry’s original function it work for you?
If so, don’t bother changing it.
@henrywright
afaik – The reason the codex page uses the wp_print_scripts hook is to insure that it runs after the wp_enqueue_scripts hook, regardless of priority.
https://codex.wordpress.org/Plugin_API/Action_Reference
The deprecation Hugo mentions is re not using print_scripts to enqueue a script, which the OP is not trying to do.
So I’m not convinced that your change to the codex page is appropriate. If you decide to stick with your change, at least update the comments above the example function to reflect that change.