If I have something like:
(use-package X
:defer t
(add-hook 'some-mode 'package-x-function))
Will that work as expected given that I set :defer t
and the package doesn't have any "built-in" autoloads and I'm not using any of the autoload-creating use-package functions? In other words, does registering a hook alone take care of loading package X given that I set :defer t
?
If not, what is the minimal additional configuration I require to make the hook work? Would I have to do something like :commands package-x-function
?