-
First, really impressed with Marten, especially the documentation which is really excellent, thanks for all the effort and care put into it! One question I couldn't find an answer to in the docs is how to handle Service Objects? In Rails and Django, there are conventions around them, but what would you suggest for Marten? Thanks in advance (note: I also asked this in Discord and I'll update this discussion if the answer is given there, and vice-versa) |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Hey! 👋 Thanks for the kind words! 😊 This is an excellent question. Presently there are no real conventions around this, and Marten projects can choose to to define service objects however they want! I am not opinionated regarding this aspect personally; if I had to define service objects in a Marten project, I would probably create a An example for a project containing the default application only:
And if the project contains multiple apps:
This is just an example, ultimately there are no guidelines or conventions around this aspect at the moment! |
Beta Was this translation helpful? Give feedback.
Hey! 👋
Thanks for the kind words! 😊
This is an excellent question. Presently there are no real conventions around this, and Marten projects can choose to to define service objects however they want! I am not opinionated regarding this aspect personally; if I had to define service objects in a Marten project, I would probably create a
services
folder under each application and define service abstraction under those.An example for a project containing the default application only: