AdonisJS: bringing order to chaos.
Meet AdonisJS: the superhero of building backend applications! Its simple, elegant, structured and perfectly opinionated. If you want full stack with everything built in, this is the one.
Introduction
In the world of web apps and APIs, JavaScript has been a dominant force for quite some time now. With the rise of Node.js, JavaScript has become a full stack language. But with great power comes great responsibility. Building a full stack application is not an easy task. It requires a lot of planning, structuring and organizing. This is where AdonisJS comes in. It is a full stack framework that is simple, elegant, structured and perfectly opinionated. It is built on top of Node.js and it is a great choice for building backend applications.
The problem with Node.js
Node.js is a great platform for building backend applications. It is fast, scalable and has a huge ecosystem. But it is also very unopinionated. This means that you have to make a lot of decisions on your own. You have to decide on the structure of your application, the database, the ORM, the authentication, the validation, the testing, the deployment and so on. This can be overwhelming, especially for beginners. This becomes even more difficult when you are working on a team. Everyone has their own way of doing things and it can be hard to maintain consistency. This is where AdonisJS comes in.
The solution: AdonisJS
It follows the “convention over configuration” principle. This means that it has a set of conventions that you can follow to build your application. This makes it easy to get started and maintain consistency. It also has a lot of built-in features that you would need to build a backend application. This means that you can focus on building your application instead of worrying about the infrastructure. It also has a growing community and a lot of documentation. This makes it easy to get help and learn new things.
ESM Support
I have had problems with importing a npm package into my existing projects because its an ESM module and i had a commonjs project. With version 6 of AdonisJS, it has ESM support out of the box. This means that you can use the latest features of JavaScript without any hassle. It makes life very easy. You can use import/export syntax, top-level await, and so on.
Powerful ORM
In the world of backend web applications, majority of the time is spent on writing CRUD operations. AdonisJS has a powerful ORM called Lucid that makes it easy to write and maintain CRUD operations. It is built on top of Knex.js and it has a lot of features that make it easy to work with databases. It has a simple and elegant API that makes it easy to write queries and it has a lot of built-in features that you would need to work with databases. It also has a lot of documentation and a growing community. This makes it easy to get help and learn new things.
Conclusion
I have been using AdonisJS for quite some time now and I am really impressed with it. I have built a lot of backend applications with it and it has made my life a lot easier. Things i can do with it in days would need weeks if i have to do it with any other framework.