Frontend backend facade of monolith. Allows to make one request to get all the data for the page.
Performs only the function of combining several responses into one.
- JavaScript's frameworks and infrastructure:
- Node.js
- Express.js
- dotenv
- Docker
- Ability to run the application in any environment
- Easy integration into Kubernetes
- Simplicity
- CI/CD
The project consists of two main modules and util packages.
First module is api:
Contains all endpoints to Mono-Backend.
Usually you need token and body from frontend.
Second module is pages:
Contains all routings for Facade and controllers for each page.
Usually controllers implements aggregate logic of Mono-Backend endpoints.
├── api (All endpoints to Mono-Backend)
│ ├── auth-api.js
│ ├── comment-reactions-api.js
│ ├── comments-api.js
│ ├── popular-api.js
│ ├── post-reactions-api.js
│ ├── posts-api.js
│ ├── profiles-api.js
│ └── tags-api.js
├── app (Facade application)
├── assets (Static assets)
├── common (Helpers and custom libraries)
└── pages (Page routings and controllers)
├── about-service
├── authentication
├── comment
├── home
├── post
├── post-create
├── profile
├── profile-settings
├── profile-subscribers
├── profile-subscriptions
├── registration
└── search
- Create
.env
file in the root project/ - As default way you can use
npm run env
- Make setup with
npm install
- Make up server with
npm run dev
For our developers and managers we use YouTrack as project management tool. So the common flow is:
- Checkout
develop
branch - Create a new branch with pattern:
feature/<TASK-NAME>
orbugfix/<TASK-NAME>
- Add feature code, write tests and check performance
- Commit changes with next description:
<TASK-NAME>: Your short description
- Make
git push
and create pull request todevelop
branch. Add some description. - Wait until reviewers approve
- Merge and deploy to testing stage.
Release flow:
- Checkout
develop
branch - Create a new branch with pattern:
release/v<VERSION>
- Create pull request to
main
branch - Wait until reviewers approve
- Deploy release to production stage and merge the pull request
Hotfix flow:
- Create a new branch with pattern:
hotfix/<TASK-NAME>
- Add code and commit changes
- Create pull request and wait approve
- Merge
If you want to add some functionality, and you are not in our team:
- Create a new branch from
develop
with pattern:contribution/<SHORT-DESCRIPTION>
- Add all code, write tests and check performance
- Commit changes with next description:
CONTRIBUTION: Your short description
- Make
git push
and create pull request todevelop
branch. Add complete description. - Wait until reviewers approve
- Pull request will be automatically merged