/to @raymondfeng@bajtos
Consider this example:
// models.json{MyBaseModel: {},SubModel: {options: {base: "MyBaseModel"}}}With methods defined in the base model like this:
// models/my-base-model.jsvarMyBaseModel=require('../app').models.MyBaseModel;MyBaseModel.myMethod=function(){}...and finally somewhere else
// some-other-file.jsrequire('./app.js').models.SubModel.myMethod()// throws undefined is not a function
/to @raymondfeng@bajtos
Consider this example:
With methods defined in the base model like this:
...and finally somewhere else