loading...

re: My confusions about TypeScript VIEW POST

TOP OF THREAD FULL DISCUSSION
re: If you look closely to the problems you are having, they are pretty much all class oriented. This is exactly what I found when picking up typescrip...
 

I definitely get this perspective, and often I do prefer a functional approach over a class based approach. However, in my experience using both query builders like knex and ORMs like Objection, I find the mental mapping between my code and the database much easier to keep straight when I have a class for each table, especially the way that Objection uses static properties like idColumn and relationshipMappings to represent database constraints. Others may feel differently, but it's how my brain works.

code of conduct - report abuse