type Method = () => unknown;

Is a Function which is mounted as JavaScript method of the class Model.


Do not use Arrow Functions to not override the this argument provided by the scope.


type Methods = { [key: string]: Method };

Specifies the JavaScript methods of the class Model. It is an Object where each key is the name of the method and the relative value is a Function which is the body of the method.


Some methods, when provided, are called by Sedentary at specific events. Please check Special methods for more details.


  • default: undefined

If provided, it works as the constructor Function does. It will be called when a new Model() is created.


TODO It is not called for loaded Entries.