A hook is a Node module that adds functionality to the Sails core. The hook specification defines the requirements a module must meet for Sails to be able to import its code and make the new functionality available. Because they can be saved separately from the core, hooks allow Sails code to be shared between apps and developers without having to modify the framework.
There are three types of hooks available in Sails:
api/hooks/folder of a Sails app. Project hooks let you take advantage of the features of the hook system for code that doesn’t need to be shared between apps.
npm install. Installable hooks allow developers in the Sails community to create “plug-in”-like modules for use in Sails apps.