Coder Social home page Coder Social logo

Comments (3)

Xeinaemm avatar Xeinaemm commented on May 22, 2024 2

Code without external dependencies - core, but more likely you should create a shared library to keep reusable code and then link this as a dependency.

Something like this:

<PackageReference Include="Ardalis.GuardClauses" />

From my perspective - I'm splitting Core into Contracts, Domain, Messages. Infrastructure into Persistence, Application, Application.Setup, Message broker. Web into UI, API(ie. API, ReadApi, PresentationApi).

Core

  • Contracts - basic models, DTOs, the definition of endpoints for API.
  • Messages - models as above but for Message Broker.
  • Domain - domain models that hold business logic in entities and value objects without EXTERNAL implementation. Just domain, root objects, etc.

Infrastructure

  • Application - implementation of business logic, CQRS that can handle commands and change domain by commands which base on external resources(other API).
  • Application.Setup - just setup to run a whole application like Autofac setup.
  • Persistence - mapping of views, tables from DB
  • Message Broker - CQRS implementation of handlers and system that run message broker service (write mode)

Web

  • API - POST Actions that invoke CQRS and then message broker(yep, next CQRS system)
  • ReadAPI - internal/external definition of data that your or any system can get
  • PresentationApi - internal read data for UI.

I just want to mention - most shareable code like CQRS, DDD base implementation that is the root of everything is from a shared library. You will not find this in the description above, but if you want to place this somewhere it would be core and shared folder.

from cleanarchitecture.

prince272 avatar prince272 commented on May 22, 2024

I just wanted to know how well you''ll be able to organize NopCommerce files using this CleanArchitecture Template.

from cleanarchitecture.

ardalis avatar ardalis commented on May 22, 2024

I'd agree with @Xeinaemm

from cleanarchitecture.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.