C
C#β€’3mo ago
SwaggerLife

Project structure

I previously had my project structured like this the problem is that, as the project grows, it getting a bit hard to maintain it. I'm trying to rethink my approach. I want to create a classlibrary project for each feature. For instance Quotifyr.Auth inside their, I want to have all my views, controllers etc related to authentication to live there. The only issue is that, since it's a classlibrary, objects such as Controller are not available? what should I do?
No description
11 Replies
SwaggerLife
SwaggerLifeβ€’3mo ago
No description
WEIRD FLEX
WEIRD FLEXβ€’3mo ago
first you should probably learn about $vsa, then let's go on from there
SwaggerLife
SwaggerLifeβ€’3mo ago
@dont/index.php I'm already doing that, I'm combining mediator with features. My features live inside Modules. I don't think this approach is efficient when it comes to very large projects.
-- Quotifyr.Auth
-- Controller
-- Commands
-- CommandHandlers
-- Views
-- Quotifyr.Auth
-- Controller
-- Commands
-- CommandHandlers
-- Views
I want a new approach. I would like to separate the features into their own projects.
Pobiega
Pobiegaβ€’3mo ago
do exactly what you plan, but instead of a classlib per feature, just have it be a folder under Features tada, problem solved πŸ™‚
SwaggerLife
SwaggerLifeβ€’3mo ago
Isn't there anyway I can seperate the features into seperate projects. I have already done some research. The problem is that, most of the packages that where used are no depricated.
Pobiega
Pobiegaβ€’3mo ago
you can, but it will cause issues like a really complicated dependecy graph once you start implementing cross-features things what if another feature needs to know about auth? and auth needs to know about that feature? oops, literally impossible
SwaggerLife
SwaggerLifeβ€’3mo ago
References?
Pobiega
Pobiegaβ€’3mo ago
so then you start making cross-functional libs, for your functional libs... :thisisfine: you cant have bidirectional references
SwaggerLife
SwaggerLifeβ€’3mo ago
Well well that sucks, It would have been really nice. If it was possible.
Pobiega
Pobiegaβ€’3mo ago
I dont really see the benefit over just having one large project with the same structure