It is now possible to add and run template hooks.