Boilerplate for Hobby Projects
As software engineers, we all have that eureka moment once in a while when we come up with a solution and just want to get into coding. But the blockage is setting up the project. A majority of us give up in the initial stages due to the silly errors that come up every time we try to set up a new project.
Well, this time when one of our team members had a unique solution to a problem we thought let us stop and make a boilerplate of the project first.
A boilerplate will have all the necessary stuff in built, so that you can focus on the solution directly instead of setting up the trivial things.
Imagine if it is a todo application that you are trying to build, it will already have —
- A robust framework that allows you to focus on the solution and not the architecture. We used NestJs for this.
- The database services are inbuilt — you will just have to plugin the database connectivity string and the database provider type.
- The configuration module is set so that managing secrets is simple
- The accounts module — No significant product can be without accounts. The boilerplate will come inbuilt with CRUD endpoints for account management.
- The authentication setup — Any project that needs an account, needs an authentication mechanism as well. This is taken care of by JWTs.
- Middleware to check authorizations. We did this via Interceptors.
- Linters, prettiers, ORMs, and data validators in built.
- Last but not least, the CI/CD and quality checkers via GitHub Actions
Keep Simplifying It
It is a continuously evolving thing as we find more and more ways to minimize the initial hiccups. Our aim is one day, it will be a one-click setup for any new product. So that you can dive right into the solution and not the setup.
And here is what we have so far — https://github.com/visakhvjn/api-boilerplate-nestjs
Feel free to raise PRs against it and use it at your convenience. Happy coding!