An opensource implementation of clean architecture on an API powered by NodeJS
- Clone the repository
$ git clone https://github.com/pupupulp/ezra-js.git
- Go to source directory
$ cd ezra-js
- Install dependencies
$ npm install
$ npm start
Note: Interface classes are used using
extends
instead ofimplements
but has a default method definition that throws a not implemented exception if the method is not overrided to simulate theimplements
behavior.
- Single responsibility principle
- Open–closed principle
- Liskov substitution principle
- Interface segregation principle
- Dependency inversion principle
Flow of Dependency - the flow of dependencies runs from the outside in, which makes the inner part of the circle independent of the outer.
-
Entities - contains all the business entities, (ex. User, Customer, etc.).
-
Use Cases - contains all the business logic, (ex. getUser, addCustomer, etc.).
-
Controllers/Presenters/Gateways - formats data in and out, and serves as an entry and exit points to use cases.
-
Frameworks - contains changeable, updateable, and removable parts of the system.
Pull requests and stars are always welcome. For bugs and feature requests, please create an issue.
You might want to checkout these projects:
- konyvtar-js - An opensource library/package of code wrappers for ExtJS 6.2.0 GPL.
- nchikota-js - An opensource tech stack composed of ExpressJS, NodeJS, ExtJS.
- passerelle-js - An opensource API gateway built with ExpressJS.
- spasojevic-js - A simulation of knowledge transfer through generations.
- neural-net-js - An opensource package to create a Neural Network.
- microservices-architecture - An opensource repository for all my learnings regarding microservices.
Eagan Martin
Copyright © 2019, Eagan Martin. Release under the MIT License