I am trying to add a method available for all controllers in sailsjs, much like the blueprint methods are. The method should also be exposed to a REST route (like /modelName/myBlueprintMethod).
How can I go about and do this?
I have seen lots of Qs for how to override the blueprint methods but what i need is extend the blueprint.
A little context.
What I want to achieve is to expose the schema of the model related to the controller to automate some front-end CMS.
Thanks