Skip to content

Commit

Permalink
docs: updated 'Ports' section
Browse files Browse the repository at this point in the history
  • Loading branch information
Sairyss committed May 18, 2022
1 parent 1005c86 commit 4626e0a
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -307,8 +307,10 @@ In Application Core **dependencies point inwards**. Outer layers can depend on i

Example files:

- [repository.ports.ts](src/libs/ddd/domain/ports/repository.ports.ts)
- [logger.port.ts](src/libs/ddd/domain/ports/logger.port.ts)
- [repository.ports.ts](src/libs/ddd/domain/ports/repository.ports.ts) - generic port for repositories
- [user.repository.port.ts](src/modules/user/database/user.repository.port.ts) - a port for user repository
- [find-users.query-handler.ts](src/modules/user/queries/find-users/find-users.query-handler.ts) - notice how query handler depends on a port instead of concrete repository implementation, and an implementation is injected
- [logger.port.ts](src/libs/ddd/domain/ports/logger.port.ts) - another example of a port for application logger

Read more:

Expand Down

0 comments on commit 4626e0a

Please sign in to comment.