Support custom methods attached to SchemaObject factory
scotthovestadt opened this issue · comments
Moving towards allowing the SchemaObject to replace Models in your code. To do this, need to attach methods to each class.
Example:
const Person = new SchemaObject({
firstName: String,
lastName: String
}, {
methods: {
getFullName: function() {
return this.firstName + ' ' + this.lastName;
}
}
});