As more and more programmers move towards a universal programming language, Javascript has been gaining popularity as a go-to language to build web and mobile applications.
But before 2009. Developers faced a challenge since the Javascript framework only allowed for client-side scripting. Then, a programmer by the name Ryan Dahl came up with the concept of Node.js, and the world became a better place to live in, at least for the programmers.
Node.js allowed programmers to use Javascript language and script server-side, which soon led to its rapid adoption across the world. Node.js slowly climbed the popularity ladder this past decade, and became the most preferred technology in 2019, according to this Stack overflow survey.
So which is the most popular Node.js framework that developers love in 2020? We asked a few of our Node.js developers here at SoluteLabs, and here is a list that we got.
1. Express.JS
Express.JS is one of the top Node.JS frameworks you should be looking at.
Bug, why do our developers love Express.JS the most? Is it the minimalistic, almost zen-like nature of the framework? Is it the ability to create both desktop and mobile applications with ease?
We would say it is a combination of all these factors and more.
At its core, Express.js is a series of middleware function calls, each having a specific task to do. It is not opinionated, which means you are free to use it in different ways.
Why do our developers love Express.JS?
- Simple framework. Easy to understand.
- Enables maintainable code and modular design.
- Easier to serve static files and resources.
- Based on HTTP methods and URLs, developers can easily define the routes of your application.
- Comes with MVC architecture. Creating eccentric apps is easier.
2. Sanity.io
Sanity.io, another top Node.JS framework, is a headless CMS System built on Node. JS technology. What is a headless CMS system? Good question. A headless CMS system provides an easier way to host the content you have. The only difference? Here, content is provided as a data instead of rendering a web page.
Wanna learn more about the fascinating world of headless CRMs? Head on over to this page. No more complaining that we don’t speak slow enough.
Why do our developers love Sanity.io?
- Ability to access fully structured content
- Extremely customizable so that it is easy to generate product documents (in markdown).
- Open source and getting started is free.
- Users can CRUD (Create, Read, Update, and Delete), edit images, information, etc.
- Can manage all of your content from one place.
3. Nest.JS
What if we wanted to build extremely adaptable, testable, and efficiently viable apps, without having to complicate things like alternating between the front end and back end? What if seamless data streaming and simple coding experience are also part of your bucket list? ( Boy, do you ever stop?)
The answer to all these questions was provided by a programmer called Kamil Mysliwiec (yup, the spelling is right, we checked) when he developed Nest.js. Nest framework is a combination of the features of Functional Programming, Object-Oriented Programming, and Functional Reactive Programming, and is built for TypeScript.
Why do our developers love Nest.js?
- Modular architecture — you can use other libraries in your project.
- Uses TypeScript and core concepts of Angular, which means Angular developers can learn it quickly.
- Apps are more reliable, thanks to TypeScript.
- Nest CLI opens the doors to an awesome set of features.
- You can build all kinds of server-side applications using Nest.
4. Koa.JS
Let’s talk about another Node.JS framework.
What word starts with a K, ends with an A, and is usually found hanging from a tree? If your answer is a Koala bear, you are probably right. But if you are a Node.JS programmer, you probably said Koa, right?
Koa is smaller, more expressive, and, all in all, a fun way to develop web apps. Like Bruce Willis and his son in Die Hard 5, if we may. It leverages async functions, meaning you can ditch callbacks and improve error-handling.
Why do our developers love Koa.JS?
- Good user experience from a very lightweight framework. At just 550 lines of code, Koa is light.
- A lot of helpful methods are available easily. Koa’s footprint is low as well!! How you may ask? Simple, no middleware is bundled.
- Writing middleware is as much fun as having a chocolate tart.
- A huge variety of customizable options, making developers happy as a toddler in a candy store.
- Control is now both upstream and downstream since there are no more callbacks.
5. Prisma.io
If you haven’t heard about Prisma, it is probably because our developers keep their knowledge of the technology as low-key as possible, leaving people wondering how they develop such robust applications with ease. Just kidding.
Prisma, as their website puts it, is an open-source database toolkit, built with one aim and one aim only — making database access easier. It does this with the help of an auto-generated and type-safe query builder. No fairies or goblins here.
Why do our developers love Prsima.io?
- Prisma helps avoid repetitive CRUD boilerplate
- No more busting your head debugging SQL or complex ORM models.
- Intuitive API. Easy to understand Javascript objects.
- Sending queries is now simple with a Prisma client.
- Use the Prisma Client alongside existing SQL queries or ORMs.
6. Hapi.JS
Ask any layman on the streets what they would use to build a Representational State Transfer (REST) APIs, and you would most likely get a confused stare back, possibly accompanied by a slap to the face for wasting their time.
Ask a developer the same question, and he would happily say Hapi.js (pun intended). Hap takes everything that was great in Express. JS, and then adds some of its capabilities to make it a sort of big brother of Express.JS. Instead of spending time building the infrastructure, developers can use that time to write reusable application logic.
Why do our developers love Hapi.JS?
- Fixing bugs and adding new features now don’t take forever.
- Build APIs for different kinds of clients, be it mobile or single-page apps.
- Plugin-based architecture makes scaling easy.
- Greater control over how requests are handled.
- Availability of authentication, caching and input validation.
7. Socket.io
Chatbots are fun to talk to, albeit a bit scary. Score tickers are an excellent way to represent some key figures, and fun to have on your website. But how are they built? Not all of us want to know. Most are just happy they have a person (or a bot) to chat with.
But for those who do wanna know, we got you covered. Socket.io is a web socket structure that is used to build all those neat things mentioned above, and more. For those who want a simpler explanation, Socket.io enables the communication between a Node.js server and a browser, which can be any browser. There you go. That is as simple as it gets for one of this Node.JS framework.
Why do our developers love Socket.io?
- Socket authentication and socket management are much easier.
- Multiple namespaces feature is handy while building an application that does a lot of back and forth push communication.
- Event encoding, allows the event name to be independent of the encoding mechanism.
- Supports a host of features such as anomaly detection, auto-correction, and multiplexing.
- Real-time analytics.
8. Loopback.JS
We have been generous with Express.JS framework. So generous, in fact, that we have placed it at the top of this list. But if you Loopback, we mean look back, you can see a couple of Node.JS frameworks on our list that are built to overcome the very drawbacks of express.js. Loopback is one among them.
Loopback is built on top of Express.JS. When this is combined with a few Node.js modules, Loopback can be used to build REST APIs for applications easily. We have covered REST APIs in an earlier part of the blog (this is for all you lazy scrollers). Loopback allows you to create APIs with little or no coding. Seriously.
Why do our developers love Loopback.JS?
- Option to run the applications on-premise or in the cloud.
- Model-relation-support. It helps users define real-world mappings between their models.
- Easier to design, build APIs, connect to databases, and test.
- Connecting devices and browsers to data is a breeze.
- Structured code and rich documentation.
That’s a wrap, folks. Eight of the most used Node.JS frameworks by our developers, along with their reasons. If you have an argument about any of these frameworks, remember, it is our developers who took the decision to put these frameworks here, and you will have to sort it out with them. Wanna know more? Write to us in the comments section below.
Top comments (27)
I'm really sad about seeing an article like this in 2020.
Because most of the information written in it is wrong and will not help any people that want to give a try to Node.js.
I'm sorry, but...
What's the goal of this article if there's so many information that can mislead newcomers to the environment?
I'm usually not very nit-picky about the distinction between a library and a framework as the line and definition is very blurred. Such distinctions have minimal actual value in the grand scheme of things. In the article's defense Socket.io calls itself a framework:
ref (search the page for the word "framework", you'll find it ;D)
I'm not sure if pointing out expressJS's flaws makes it "wrong" to mention in an article of recommendations. I'm also not sure if this criticism is provided mainly just to boost AdonisJS credibility in an article that didn't include it.
Finally, the article gave its premise of where this list came from:
It might be fair to say that the title of this article is slightly misleading as not all of this stuff is nodejs frameworks, but to label it as "wrong and wont help anyone trying nodejs" seems unnecessarily critical at best, or a blatant plug for AdonisJS at worse.
Hey Brad!
It's important to point the flaws of a system. When you need to choose a stack, it's necessary to have the pros and the cons. Nearly all Node.js tutorials will showcase ExpressJS, at the point of people thinking you cannot do Node.js without ExpressJS! I must say that I'm a bit tired to see people keep recommending it despite what I said in my first comment.
I've put the first sentence to remove this thinking, but it may still sound like an advertisement for it. I've removed that part to avoid the confusion.
I agreed, the definition is very blurry. I believe that a framework should help you focus on what pays off for your business like Rails or Laravel are doing.
Sam Selikoff made a great video called React is a programming language for UIs that explain what he expects from a framework.
That's my main concern. People tend to not overthink when they read. Reading this article may mislead beginners because they may start a project using something which will not help them.
Time to sleep for me, it's past 2 am, I'll read you tomorrow!
As you said, ExpressJS is almost synonymous with nodejs. Not including any mention of it, either by omission or by accident would be a pretty big problem for almost any article covering the topic of nodejs development.
Expecting an article on general nodejs development that doesn't include any mention of expressJS probably isn't a very reasonable expectation.
This article's primary focus is on informing what a few devs at SoluteLabs recommended via an internal survey. Its not the most "scientific", hence why I think the hapi.js recommendation got in. I also think that is why there is 0 "cons" anywhere on this page.
I'd hope any one starting out does look into the pros and cons and not just this article (or any single article), which probably should be considered "a light skim" of what SoluteLabs uses than a rigorous comparison of different technologies.
Now on the topic of "they may start a project using something which will not help them." is only mostly true for hapi.js due to it effectively being a legacy framework. To apply that logic to expressJS and koa seems to just go back to the thinking that recommending expressJS is "wrong" due to its flaws. Which seemed to exist only to promote AdonisJS, either consciously or even unconsciously.
If you have 1 technology, see an article that promotes other technology that has "flaws" that are covered by your technology, I can see it being seen as "wrong" and wanting to bring notice to your technology. I think that's fair for relevant self promotion, however, what you see as "wrong" isn't necessarily wrong from all perspectives, especially when an article is setup in a non exhaustive way such as this one.
I believe, this thread has turned into a reddit thread.
I am no one to judge. But, I believe, as the reader, we should demand for high quality and well researched articles.
If you open an article from 2015 and read this, you will not find any major distinctions and I refuse to believe, that the Node.js landscape hasn't been changed yet.
Cheers!
I'm going to be critical about your point regarding Prisma. Despite the fact that Prisma absolutely behaves in many ways like an ORM, the developer team has specifically written an article specifying that Prisma is infact not an ORM.
prisma.io/docs/understand-prisma/p...
I've come across more terrible articles (even on dev.to) but "the ability to create both desktop and mobile applications" yeah that seems a bit ... uninformed?
The good thing is that the author mentions that these are the preferred choices of her company's developers, although it would be even better to mention that at the start of the article :-)
The weirdest thing for me was that the article starts off by showing a chart of "most popular technologies" and then goes on to list a bunch of the most unrelated tech you can imagine, from game engines and big data platforms and from devops tools to mobile development frameworks ...
What knowledge do I gain from that, or what purpose could possibly be served by this bizarre apples and oranges collection? It would obviously be way more interesting to show how node.js compares to other web app backend frameworks (i.e. same category) like Rails or Laravel and so on.
AdonisJS for the win!!
I believe AdonisJS should be added to list. preview.adonisjs.com/. The framework offers a different perspective to creating apps in Node.js.
Whereas ExpressJS hasn't been maintained for years and Hapi is shutting down. twitter.com/nmarsup/status/1278980.... Yes sad news :(
I agree. this is a poorly written and outdated infos
What about AdonisJS ?
Thanks, this was very helpfull.
Is sanity is better than strapi ?
Yeah I was going to ask that, is it ?
Yes, coz sanity is paid and strapi is completely free. though sanity have a limited free version
I think that AdonisJs should be added to list. It's a framework awesome and real bakcend framework for JavaScript/NodeJs
Fastify is definitely up-and-coming as well. It's definitely much faster than a lot of the other frameworks and the documentation is 👌
fastify.io/
"Wanna learn more about the fascinating world of headless CRMs? Head on over to this page."
Which page?
hapi.js is twitter.com/hapijs/status/12758879...
the tweets were unhapi
I would add TS.ed (Typescript Express Decorator). I can see Adonis.js like a kind of Laravel for Node and TS.ed just like a Symfony for Node.
tsed.io/
MongooseJs???