Need advice about which tool to choose?Ask the StackShare community!

NestJS

2.5K
2.8K
+ 1
326
Spring Boot

25.2K
22.8K
+ 1
1K
Add tool

NestJS vs Spring Boot: What are the differences?

NestJS and Spring Boot are frameworks, used for building scalable and efficient web applications. NestJS is a TypeScript-based framework inspired by Angular, while Spring Boot is a Java-based framework built on top of the Spring framework. Let's explore their key differences:

  1. Language and Ecosystem: NestJS leverages the extensive JavaScript ecosystem and benefits from features like strong typing, decorators, and modern JavaScript syntax. Spring Boot, on the other hand, is a widely adopted programming language with a vast ecosystem of libraries, frameworks, and tools. It integrates seamlessly with the Java ecosystem and benefits from mature tooling and community support.

  2. Architecture: NestJS follows a modular architecture pattern inspired by Angular, allowing developers to organize their applications into reusable modules. It promotes the use of decorators and dependency injection to create scalable and maintainable applications. Spring Boot follows the layered architecture pattern and promotes the use of Inversion of Control (IoC) and Dependency Injection (DI) principles. It provides a rich set of features for building enterprise-grade applications, such as transaction management, security, and data access.

  3. Framework Features: NestJS provides a built-in set of features, such as routing, middleware support, exception handling, and dependency injection. It also offers support for GraphQL, WebSockets, and microservices architecture through various modules and libraries. Spring Boot offers a comprehensive set of features for web development, including routing, request handling, database access, security, caching, and more. It provides robust support for building RESTful APIs and integrating with various technologies like messaging queues, databases, and caching solutions.

  4. Community and Documentation: NestJS has a growing community and an active developer ecosystem. It benefits from the knowledge and resources available in the larger JavaScript and TypeScript community. The official NestJS documentation is well-structured and provides detailed explanations along with practical examples. Spring Boot has a mature and extensive community, with a wealth of resources and community-driven libraries available. It benefits from the vast knowledge base of the Spring framework and Java ecosystem. The Spring Boot documentation is comprehensive and provides detailed guidance on various topics.

  5. Performance: NestJS leverages the performance benefits of Node.js and TypeScript, making it a suitable choice for high-performance applications that require real-time communication or handling a large number of concurrent requests. Spring Boot, being based on Java, offers robust performance and scalability. It benefits from the mature Java Virtual Machine (JVM) and optimized runtime environment, making it well-suited for enterprise-level applications with high traffic loads.

In summary, NestJS offers a modular and scalable architecture inspired by Angular, making it suitable for creating robust and maintainable backend systems. On the other hand, Spring Boot, based on Java, provides a comprehensive ecosystem and extensive libraries, enabling rapid development and deployment of enterprise-grade applications.

Advice on NestJS and Spring Boot
Needs advice
on
DjangoDjango
and
Spring BootSpring Boot

I need to build a system(web app) where people will share their projects and will receive funding against those projects if someone likes the projects. The backend should be secure, and the tools that will be needed to build that system should be free. We are a startup that can't invest too much in tools right now. We need to build it in 3-4 four months.

The application should be able to support 10k users for now and should be able to scale later.

Also, please suggest what front-end technologies I should use.

See more
Replies (1)
Top Notch

Depending on the backend I would pick the technology you feel most comfortable with, although, my preference would go to Django with Django REST Framework considering the timeframe you mentioned.

As for the front-end, React.JS and Vue are easy to get started with.

See more

Is learning Spring and Spring Boot for web apps back-end development is still relevant in 2021? Feel free to share your views with comparison to Django/Node.js/ ExpressJS or other frameworks.

Please share some good beginner resources to start learning about spring/spring boot framework to build the web apps.

See more
Replies (1)

Java in general, in my opinion, is somewhat outdated in 2021. C# is a better language, and therefore, I think ASP.NET (Core/.NET 5) should be used over it. Node.js isn't bad if you are getting started, or if you need to prototype an app. I use Node in production because of TypeScript, but .NET is a really good framework that has excellent performance.

See more
Rafsanjanee Rizvi
Owner at Mingchen Information And Technology · | 4 upvotes · 370.6K views
Needs advice
on
ExpressJSExpressJSNestJSNestJS
and
Spring BootSpring Boot

Hi, I am a new developer using Ionic to develop a mobile app. I have recently tried to build a social mobile app which will have video calling, payment transaction, chatting, sharing, etc. I am now confused as to which framework I should use for the backend: Spring Boot or ExpressJS or NestJS? Any detailed advice will be better for my development. Looking forward to your valuable reply.

See more
Replies (2)

Any tools that achieve your software functionalities is good. you should check if with these frameworks you can do video-call, chat etc. how the scalability is achieved and the complexity of using it with them. since you are starting from scratch you can do this kind of feasibility before starting

See more
Recommends

If I want to write server api, I will use NestJS as primary framework. It base on express | fastify so I can use anything of expressJs. SpringBoot is a java framework. I will think to write as payment transaction service. If you are Ionic developer. you will know Js / ES6. You can try NestJS / ExpressJS. - video calling: You can not create video calling feature. Some keywords: ffmpeg / coturn / webrtc - chatting: realtime (socket.io / websocket) - you can try some opensource as rocketchat. It also have video calling feature.

See more

Hi

I’ve been using Django for the last year on and off to do my backend API. I’m getting a bit frustrated with the Django REST framework with the setup of the serializers and Django for the lack of web sockets. I’m considering either Spring or .NET Core. I’m familiar with Kotlin and C# but I’ve not built any substantial projects with them. I like OOP, building a desktop app, web API, and also the potential to get a job in the future or building a tool at work to manage my documents, dashboard and processes point cloud data.

I’m familiar with c/cpp, TypeScript.

I would love your insights on where I should go.

See more
Replies (3)
Recommends
on
.NET Core.NET Core

Theres a logt going on in the dotnet world. I currently do all my Rest APIs with asp.net core.

The Setup is very easy as the .net web sdk provides with a lot features you don't want to keep yourself concerned with. You can integrate Swagger with little effort.

See more
Dzung Nguyen
Researcher at Florida Institute of Technology · | 6 upvotes · 360.8K views
Recommends
on
Spring BootSpring Boot

Spring Boot is the lightweight of the Spring framework. I used the Spring framework before, and I fall in love with the Spring Boot. I also use .NET core, but still, I like Spring boot the best. If you have time then you should experience both. You are more than halfway in gaining experience. My suggestion is always to try to learn many things as you can.

See more
Nikhil Gurnani
Sr. Backend Engineer at Grappus · | 4 upvotes · 355.6K views
Recommends
on
Spring BootSpring Boot

I see what you're going through and I extend my hands to you. I felt the same frustration after almost 1.5 years of working with Django and Node.js in the parallel. And since the last one year, I've transitioned into Spring Boot. I think its fair to say, that its quite different when you're going from Django background as a framework, but otherwise. I think it's one of the robust ones out there. Scalability is seamless and you get most of the things out of the box or easily supported by dev dependencies. You should definitely check it out! :)

See more
Eva Maciejko
Needs advice
on
ExpressJSExpressJSLaravelLaravel
and
Spring BootSpring Boot

Hello, I am a fullstack web developer. I have been working for a company with Java/ Spring Boot and client-side JavaScript(mainly jQuery, some AngularJS) for the past 4 years. As I wish to now work as a freelancer, I am faced with a dilemma: which stack to choose given my current knowledge and the state of the market?

I've heard PHP is very popular in the freelance world. I don't know PHP. However, I'm sure it wouldn't be difficult to learn since it has many similarities with Java (OOP). It seems to me that Laravel has similarities with Spring Boot (it's MVC and OOP). Also, people say Laravel works well with Vue.js, which is my favorite JS framework.

On the other hand, I already know the Javascript language, and I like Vue.js, so I figure I could go the fullstack Javascript route with ExpressJS. However, I am not sure if these techs are ripe for freelancing (with regards to RAD, stability, reliability, security, costs, etc.) Is it true that Express is almost always used with MongoDB? Because my experience is mostly with SQL databases.

The projects I would like to work on are custom web applications/websites for small businesses. I have developed custom ERPs before and found that Java was a good fit, except for it taking a long time to develop. I cannot make a choice, and I am constantly switching between trying PHP and Node.js/Express. Any real-world advice would be welcome! I would love to find a stack that I enjoy while doing meaningful freelance coding.

See more
Replies (10)
Recommends
on
Spring BootSpring Boot

Hi Eva, As you have solid experience with Spring already, you should jump into freelancing with that. It would be quite stressful to start freelancing with a tech stack you don't know well. Then in the background you can keep learning/practicing an alternative and switch over when you are confident enough (eg. 0.5-1 year later). I think you should learn Laravel as you already like it and find it easier. Express has better performance but that is not required for most of the small freelancer projects.

See more
Recommends
on
ExpressJSExpressJS

Looking at current technological trends and rise of JavaScript, you cannot go wrong with JavaScript. - There's an abundance of libraries to get most things done - You can use JavaScript for both the frontend and the backend - this allows you potentially share your logic/models/code across both stacks - A dynamic/interpreted language such as JavaScript is great for serverless (there's somewhat of a trend towards serverless aswell - especially in modern projects) - If you like/need static typing, you can always migrate seemlessly to Typescript - VueJS is a lightweight framework (compared to Angular), it has more GitHub stars and most would argue it's easier to work with (beginner friendly). Additionally most modern webapps do not use JQuery anymore (even though a lot of legacy projects continue to do so). You don't need JQuery if you use Vue/Angular/React

Additionally it doesn't seem like performance is a hugely important metric in your scenario, so JavaScript would suffice.

Note: These are all my opinions and what I've seen in the current market when recently searching for jobs.

See more
Benoît Hubert
JavaScript Instructor at Wild Code School · | 6 upvotes · 660K views
Recommends
on
Spring BootSpring Boot

I think Patrik and Alex are right: if you're comfortable with Spring Boot already, you'll be more productive right from the start.

If you wish to learn something else besides, both Laravel and Express are good choices. They aren't in the same category of frameworks: Laravel is an all-in-one solution, while Express is more like "build your own stack from different parts". Which implies that you can use whatever you want as a database engine: MySQL or PostgreSQL are perfectly valid choices (in my school, we teach Express with MySQL, because SQL is still a big thing here in France, and a sought-after skill). You can use Sequelize or TypeORM which support all major SQL DBMS.

Express is widely used, but if you're seeking the JavaScript equivalent of Spring Boot or Laravel, you probably want to look at NestJS. The only potential downside is that it's still young, maintained by a small commmunity, compared to those behind Spring Boot and Laravel.

Bottom line: using a stack tech, that you enjoy and are comfortable with, matters. Spring Boot + Vue.js seem perfectly fine to me. But do forget jQuery if you're using Vue.js, React or Angular, because it will definitely bring more harm than good!

See more
Muhammad Waleed
The Community Management · | 5 upvotes · 668.6K views
Recommends
on
Spring BootSpring Boot

I would definitely recommend you to go with Spring Boot + AngularJS + jQuery. Reasons: 1- You have an experience of 4 years with the above-mentioned stack. 2- As you mentioned that you wish to work as a freelancer, your stack is the perfect one for finding good bids with a little less effort than that of PHP + Laravel + Vue.js.

See more

Hi as someone who employs and select developers i agree with a lot almost sayed but think of what are your strengths and where you are or better where your customers are. If you search for big enterprise projects spring boot is ok sql is must and html css as well. if you want to go more to internet related companies (like airbnb, what sup, facebook ) or similar (and not asia) then react is a must node js as well. The libraries tools etc which are used you need to adopt fast. If asia then VUE is a must. but if you like small projects with individuals or like wordpress or similar then you can learn php but i think in 2020 it is wasted time. Same for python in that area. and i also see that we often have problem that developer at least must understand docker docker compose better as it works with kubernetes ,.. just my 5 cents

See more
Alex Spieslechner
Recommends
on
Spring BootSpring Boot

in order to stay employable, I'd work with something you can deliver with. if I'd be your client and you'd have to get comfortable with a new stack, I would 100% not pay you for this startup time. learn new stuff in your free-time. or set aside time for learning.

that said, if you want to reorientate, php (even though i personally hate it) is extremely wide spread. but so are java and nodejs. so I'm not a fan of that argument... i recommend building something in each language, and see what you enjoy more. for me it was nodejs, because I already enjoy frontend JavaScript, and appreciate the ecosystem and community.

regarding expressjs and mongodb: yes, it is a goto solution for a lot of tutorials, because its as simple as it gets. especially wben using something like monk. BUT if you want to use mysql, posgres or similar, check out TypeORM, Prism or another ORM-like solution. you can use any db with express, and there's plenty of abstraction layers, which make your life easier. but i noticed that expressjs does a lot less "holding hands" compared to .net core (c#), or laravel (php). can be a pro or a con.

See more
Rubin Thomas
Software Cloud Developer at RUBIN THOMAS · | 4 upvotes · 599.5K views
Recommends
on
PerlPerlPHPPHPPythonPython

As a developer myself, I would recommend you not to restrict yourself to JAVA, PHP or any other language. New Tools/languages keep coming every day. If you do plan to move to freelancing. PHP has a lot of options in the freelance space and a lot of competition too.

Learning PHP is as simple as learning any other language. It depends merely on your interest.

Personally if you can code, you should not restrict yourself. I have had to code in many languages, PHP, Perl, shell script, Python, Java, Javascript, Ruby etc... I would keep your developing skills and logic, algorithms etc.. and increase your knowledge and experience in the different languages.

I agree with you JAVA is a lot more time consuming. But it also has its enterprise level scope.

At the same time learning a new language should not be a barrier for you to stop exploring what's out there and keeping your skills up to date. Learning new technologies should be your primary focus and getting project out of your stack helps you build a good reputation.

There are many options for you to pursue. Having an open mindset will help you move forward. If you look to learn now, you are setting yourself up for a brighter future.

See more
Recommends
on
ExpressJSExpressJSLaravelLaravel

I like fullstack freelancers who stacks are clean as one of below

  1. PHP (laravel ) + Jquery + Bootstrap

  2. Python(Django) + Angular JS or VueJS

  3. NODEJS + REACTJS

See more
Ahmed Gamal

Please, try to work with your comfortable stack, here is some recommendation

See more
Recommends
on
ExpressJSExpressJS

Hey There, I would recommend going fullstack javascript since you already have experience with javascript on the front end it would be very easy to pickup node and express js. You can use sql with node and express if you please, but mongo is pretty easy to get going with.

See more
Needs advice
on
DjangoDjangoNestJSNestJS
and
Spring FrameworkSpring Framework

Hi there, I'm deciding the technology to use in my project.

I need to build software that has:

  • Login
  • Register
  • Main View (access to a user account, News, General Info, Business hours, software, and parts section).
  • Account Preferences.
  • Web Shop for Parts (Support, Download Sections, Ticket System).

The most critical functionality is a WebSocket that connects between a car that sends real-time data through serial communication, and a server performs diagnosis on the car and sends the results back to the user.

See more
Replies (4)
Recommends
on
NestJSNestJS

You can use NestJs with microservice architecture.where you can also use socket.io for web socket. you can use MongoDB (For real-time data) & MySQL for customer management.if you don't want to implement websocket.you can use firebase.it gives realtime database & firestore.which can handle millions of connections and scale it up.

See more
Mohammad-Ali A'râbi
Software Engineer at AppTec GmbH · | 5 upvotes · 206.3K views
Recommends
on
NestJSNestJS

I would also go with NestJS. I would say Java is unnecessarily complicated and limited. And Python is not typed. TypeScript is powerful and typed and goes well with NestJS, especially using RxJS.

Django does not enforce backend-frontend separation, which probably was a good thing back in the days, but not anymore. But on the other hand enforces the project structure to you, which I don't like.

See more
Amit Parameshwar
NodeJS Intern at CartRabbit · | 3 upvotes · 562.2K views
Recommends
on
Node.jsNode.js

Just a simple Node.JS app with templating engine for UI can be sufficient for what you want to achieve.

See more
Recommends
on
Spring FrameworkSpring Framework

Spring boot with Spring Security[JWT], Websocket, Thymeleaf or Mustache, and styling with Bootstrap.

See more
Slimane Deb
Needs advice
on
NestJSNestJS
and
Spring BootSpring Boot
in

I am currently planning to build a project from scratch. I will be using Angular as front-end framework, but for the back-end I am not sure which framework to use between Spring Boot and NestJS. I have worked with Spring Boot before, but my new project contains a lot of I/O operations, in fact it will show a daily report. I thought about the new Spring Web Reactive Framework but given the idea that Node.js is the most popular on handling non blocking I/O I am planning to start learning NestJS since it is based on Angular philosophy and TypeScript which I am familiar with. Looking forward to hear from you dear Community.

See more
Replies (2)
Recommends
on
NestJSNestJS

NestJS is an excellent framework (they both are). I would say the fact that you're working with Angular makes NestJS a great match, unless you're splitting front and back end between developers. But even in that case I would still go with NestJS for a new project.

Regarding the single threading point, take a look at PM2 which helps to run Node in multiple processes (we use it with NestJS) https://pm2.keymetrics.io/docs/usage/cluster-mode/

Also regarding web server performance in general this is an interesting post showing how Node with outperform Java in a web situation (be careful though, best to check a few posts to make sure these aren't totally biased benchmarks!): https://www.tandemseven.com/blog/performance-java-vs-node/

See more
Recommends
on
KotlinKotlin

Node.js has only 1 real thread per process; Java JIT will mostly run faster than JS one; So if it happens to be not only I/O... Why do you need most popular, not simply popular? Does Node.js have tech advantages?

See more
Taimoor Mirza
Associate Software Engineer at Intech Process Automation · | 5 upvotes · 718.4K views
Needs advice
on
ASP.NET CoreASP.NET Core
and
Spring BootSpring Boot

For context, I currently use JavaScript (React) and Python (Flask) in my daily routine.

I need your help in choosing either Spring Boot or ASP.NET Core. Both frameworks seem to have mature ecosystems. I would like to hear your thoughts on the following points:

  • Difficulty level of both frameworks
  • Level of community support
  • Career prospects i.e do Spring based jobs pay more or vice versa
  • which one will be helpful if I decide to transition towards a more specialized field like data engineering.

I am asking this because it is something that I am also exploring in parallel. I know that Python and #SQL play a huge role in big data.

See more
Replies (4)
Keegan Witt
Recommends
on
Spring BootSpring Boot

I'll preface this by saying I haven't ever done work on the Microsoft stack, so take this with a grain of salt.

Community support: Java tends to have a more active community (and much more diverse universe of new open source projects) than .Net (related to below).

Difficulty level: I'd say the Java/Spring stack is more difficult because Java developers tend to use more community projects and have to know which ones to choose in which circumstances (e.g. what logging framework to use? What database connection pooling library to use? What testing framework to use). That being said, most decisions you have to make have choices that are vastly more popular than others. My impression is that .NET guys use stuff from the standard library almost exclusively. If it's not provided there, it's a problem they never thought to solve or maybe write their own (usually the former).

Career prospects: I'll get hate for this probably, but Java/Spring has more jobs than .Net. .NET Core even more so because it's new. Most .NET jobs out there are going to be not Core, and not on anything other than Windows. LinkedIn search for jobs in United States shows 97,103 for Java and 36,448 for C#. That's not to say some individual city might not have more .NET than Java, but by and large Java is bigger. Also, .NET is not dying at the same pace as say Ruby on Rails (sorry Rails fans). I'd say it's ticking very slowly lower, maybe even holding steady. I wouldn't say you're screwed career-wise if you choose .NET. C# is also pretty similar to Java from what I've seen, and I know professionals that have transitioned to Java (though interestingly, I don't know any that did the reverse). Several companies have basically no .NET footprint, for example, Amazon, Google, Facebook, LinkedIn, Twitter all have Java, but basically no C#.

Specialized fields: Neither Spring or .Net are going to be a thing in a field like data science. That's exclusively Python (some R) for the most part. The only exception being that there is some Java in Hadoop, and Scala in Spark (which runs on the JVM). But I think those are generally more for data products being created, and not data science work. I'm also under the impression this is increasingly less the case than historically. Some other specialties might make Java useful, for example Android development.

In short, Java is the COBOL of the modern enterprise (which is both a good and bad thing). I recommend it to anyone over .NET, but not for technical reasons. It's for reasons related to the questions you asked. There are actually reasons I think CLR and C# are actually better from a technical perspective than Java (unsurprisingly, since they had the benefit of hindsight). But that's not what you were asking about...

See more
Recommends
on
Spring BootSpring Boot

Spring boot helps you creating microservices in hours, not days and there is a very active community around it with amazing integrations. Check one of the tutorials maybe. At least here in Germany, the job market will be better for Spring Boot as well, there are a lot more companies using Java then C#.

See more
Alexandru Muntean
Java Application Architect at IBM · | 4 upvotes · 527.5K views
Recommends
on
Spring BootSpring Boot

ASP.NET Core is pretty new while spring boot is very old but with a different name. Spring boot is just a pack of spring packages which make your life easier. I also believe that java community is way stronger than c# community... You can do your job in both frameworks and it's up to you what you choose after-all you're going to work on the project/lead it ... but whatever you choose.. after a few days of investment stick with your decision because in both frameworks you'll encounter challenges :)

See more
Klaus Nji
Staff Software Engineer at SailPoint Technologies · | 3 upvotes · 515.1K views

I’ll echo what others have said here with a few twists.

I have experience with both platforms including Micronaut, a relatively new kid on the block. It all depends on your near term goal. If it is to make money, sure Java jobs pay more generally because there is more hassles when dealing with the entire ecosystem. Like someone said earlier, you have to make a decision at almost every stage of the development cycle from the IDE, dependency resolution framework, logging, serialization, microservice framework etc. There is just too much choice which some may argue is an advantage while others may argue is a distraction and productivity killer. At the end of the day you can build solid systems with both frameworks.

Coming to ASP Core, yes I also agree that options are more streamlined. You’ll be using Visual Studio or Visual Studio code. For dependency management, you’ll be using Nuget. But I disagree with one of the comments above about the lack of choice. In some aspects .NET actually has more choice believe it or not for example choice of ORM. There is entity framework, nhibernate, dapper etc. For J2ee, hibernate reigns supreme although you have JPA. For dependency injection you have many IoC containers like unity, castle Windsor in .NET while you have Guice and maybe a Spring based implementation.

Also C# is technically a better language that Java. That’s not questionable as has also been stated above. Many things are done right obviously by avoiding some of the mistakes made in the underlying architecture surrounding the Java programming language. That’s why Microsoft created c# to begin with. The language is a lot cleaner and allows you to focus on learning core principles and nail down fundamental OO with emphasis on good design. I find too many distractions in the Java ecosystem which takes me away from understanding the core problem I am trying to solve.

So as you can this is not an easy decision and as someone has stated there’s work to do regardless of what technology choice you make.

If your sole purpose is to make a higher base salary, sure pick Spring Boot. If you want to quickly deliver something and iterate, pick ASP Core. I personally use c# for all private projects and proving concepts even though my employer is a Java shop. It allows me to stay focused on solving the problem and not constantly wrestle with issues such as Gradle dependency resolution glitches in IntelliJ.

Given that you can transfer skills from .NET to J2ee I recommend guys to pick up ASP get a couple of services to get a feel web development as you can still get jobs in Java even with that experience. Companies don’t care these days. In fact a lot of companies are going to Go so there’s that too.

Depends on your immediate term goal.

See more
Louai Hamada
Full Stack Web Developer · | 7 upvotes · 510.3K views
Needs advice
on
ExpressJSExpressJSNestJSNestJS
and
Node.jsNode.js

I'm planning with a small team to create an application which is a platform for restaurants. I'm on the backend almost alone currently. I'm going to use Node.js for that, and I'm very fond of TypeScript, and I worked before mostly with ExpressJS. The team may get bigger as the application becomes bigger and more successful, so I have the Scalability concern in mind now, and I was considering these options: 1) Use Node+Express+Typescript 2) Use Node+NestJs (which utilizes Typescript by default)

Option 2 is enticing to me because recently I came to love NestJS and it provides more scalability for the project and uses Typescript in the best way and uses Express under the hood. Also I come from an Angular 2 background, which I think is the best frontend framework (my opinion, and I know React quite well), which makes Nest feel familiar to me because of the similarity between Nest and Angular. Option 1 on the other hand uses Express which is a minimalist framework, very popular one, but it doesn't provide the same scalability and brings decision fatigue about what to combine with it and may not utilize Typescript in the best way. Yet, on the other hand, it is flexible and it may be easier to manipulate things in different ways with it. Another very important thing is that it would be easier in my view to hire Node developers with skills in Express than NestJs. The majority of Node developers are much more familiar with JavaScript and Express.

What is your advice and why? I would love to hear especially from developers who worked on both Express and Nest

See more
Replies (6)
Wender Machado
Full Stack Engineer at RG Sistemas · | 9 upvotes · 397.6K views
Recommends
on
NestJSNestJS

I highly recommend NestJS because:

  • It's a framework you already like;
  • Typescript is growing fast, being increasingly adopted in the community;
  • All layers are well defined, not needing to think much about the organization;
  • Great documentation;
  • Nest CLI increases the development speed and keep the pattern;

Only using express and knowing that project can grow, you'ill need to define the structure well so that it doesn't get out of control.

See more
Rhoger Anacleto
Developer at Magrathea Labs · | 5 upvotes · 397.6K views
Recommends
on
NestJSNestJS

Hi Louai,

I am quite sure that you know the answer to your problem. And I am here to help you to follow your arrow. I have worked with the most popular Nodejs frameworks and I can sure you that there's no stack better than NestJS (at all). Typescript is the best thing that happened with Javascript, this is a fact. Ans NestJS make a such wonderful job using all the best Typescript tools. NestJS is the most mature and organized API manager. Its modular dependence injection, the use of DDD, the solid idea of single responsibility, it's unit a and e2e testing support, its documentation is the most incredible work in the world of Nodejs. You won't regret choosing this framework, even if your application grows a lot. If you follow the documentation tips you will be able to create an amazing and organized application.

ps: I am not part of the NestJS team, I am just a guy tired of wasting time with dumb and bad Frameworks and its bad documentations. I find relief in NestJS with all the time it's saved to me, it helped me to improve my job and let me create great things with Nodejs.

See more
Recommends
on
NestJSNestJS

I would definitely suggest NestJs over other options because NestJs gives a lot of tooling. it would definitely suggest NestJs over other options because NestJs gives a lot of tooling & it gives a lot of functionality out of the box. If your team worked with angular 2+ then it will really easy to learn.

See more
Recommends
on
NestJSNestJS

First of all, my experience using either Node.js with Express or NestJS is not wide. I liked NestJS due to it's similarity to Angular, so when you know Angluar and like TypeScript you are going to love NestJS, it will be instantly very familiar and easy to use, it's adds a good structure to the project out of the box and well, it uses TypeScript, which is a more structured language - it's good for scalability. As for performance concern s - NestJS is based on Node, it just brings Angular's modular structure to it, so the question is more about how is the additional layer influences the performance - I cannot answer that.

See more
Recommends
on
NestJSNestJS

Hi, I'm in a similar position, but related to personal projects. After falling in love with few frameworks in the first day and rejecting them in day 2, I started learning nestJS last week. I currently develop personal side projects using cakephp, and I intend to migrate to nest + vue. This week I'm taking a nestJS course in order to be sure that this is what I want by praticing a little. If you didn't do it yet, I suggest you try to code a todo app or a similar example API using nest, so you can "feel" if this is indeed what you want to use in this larger-scale project.

Some of the characteristics that got my attention to nestJS are typescript, a lot of annotations/decorations, an oppinionated approach to organizing the project, nice documentation and discord, and it's evolution at npm trends shows me it's probably not going to vanish or get buggy anytime soon.

See more
Recommends
on
hapihapi

Have you checked out Hapi as an alternative? I'ts not Typescript by default though. If that doesn't seem too interesting, it sounds like you want to go with NestJS :)

See more
Needs advice
on
Node.jsNode.js
and
Spring BootSpring Boot

Hi, I am looking to select tech stack for front end and back end development. Considering Spring Boot vs Node.js for developing microservices. Front end tech stack is selected as React framework. Both of them are equally good for me, long term perspective most of services will be more based on I/O vs heavy computing. Leaning toward node.js, but will require team to learn this tech stack, so little hesitant.

See more
Replies (1)
Max Musing
Founder & CEO at BaseDash · | 10 upvotes · 489.3K views
Recommends
on
Node.jsNode.js
at

It's probably worth investing some time for your team to learn Node.js. There's very little overhead, especially with a framework like ExpressJS, so if your team is familiar with JavaScript it should be a quick process.

It handles I/O really well out of the box, and has a strong community with great open source libraries. Since you're using React on the front end, there's also some benefit to being able to use JavaScript throughout your stack.

See more
Decisions about NestJS and Spring Boot
Hampton Catlin
VP of Engineering at Rent The Runway · | 7 upvotes · 415.1K views

Starting a new company in 2020, with a whole new stack, is a really interesting opportunity for me to look back over the last 20 years of my career with web software and make the right decision for my company.

And, I went with the most radical decision– which is to ignore "sexy" / "hype" technologies almost entirely, and go back to a stack that I first used over 15 years ago.

For my purposes, we are building a video streaming platform, where I wanted rapid customer-facing feature development, high testability, simple scaling, and ease of hiring great, experienced talent. To be clear, our web platform is NOT responsible for handling the actual bits and bytes of the video itself, that's an entirely different stack. It simply needs to manage the business rules and the customers experience of the video content.

I reviewed a lot of different technologies, but none of them seemed to fit the bill as well as Rails did! The hype train had long left the station with Rails, and the community is a little more sparse than it was previously. And, to be honest, Ruby was the language that was easiest for developers, but I find that most languages out there have adopted many of it's innovations for ease of use – or at least corrected their own.

Even with all of that, Rails still seems like the best framework for developing web applications that are no more complex than they need to be. And that's key to me, because it's very easy to go use React and Redux and GraphQL and a whole host of AWS Lamba's to power my blog... but you simply don't actually NEED that.

There are two choices I made in our stack that were new for me personally, and very different than what I would have chosen even 5 years ago.

1) Postgres - I decided to switch from MySql to Postgres for this project. I wanted to use UUID's instead of numeric primary keys, and knew I'd have a couple places where better JSON/object support would be key. Mysql remains far more popular, but almost every developer I respect has switched and preferred Postgres with a strong passion. It's not "sexy" but it's considered "better".

2) Stimulus.js - This was definitely the biggest and wildest choice to make. Stimulus is a Javascript framework by my old friend Sam Stephenson (Prototype.js, rbenv, turbolinks) and DHH, and it is a sort of radical declaration that your Javascript in the browser can be both powerful and modern AND simple. It leans heavily on the belief that HTML-is-good and that data-* attributes are good. It focuses on the actions and interactions and not on the rendering aspects. It took me a while to wrap my head around, and I still have to remind myself, that server-side-HTML is how you solve many problems with this stack, and avoid trying to re-render things just in the browser. So far, I'm happy with this choice, but it is definitely a radical departure from the current trends.

See more
Radoslaw Fabisiak

We builded Duomly with: BE: Node.JS & Nest.JS & TypeScript & PostgreSQL and FE: React & Sass & Javascript.

The whole of the stack is JS related what helps us to keep development on a track. When building backend we decided to go go for TS & Nest.js because we had experience with Javascript and still wanted to have control over types.

See more
Get Advice from developers at your company using StackShare Enterprise. Sign up for StackShare Enterprise.
Learn More
Pros of NestJS
Pros of Spring Boot
  • 54
    Powerful but super friendly to work with
  • 42
    Fast development
  • 40
    Easy to understand documentation
  • 36
    Angular style syntax for the backend
  • 32
    NodeJS ecosystem
  • 31
    Typescript
  • 27
    Its easy to understand since it follows angular syntax
  • 18
    Good architecture
  • 13
    Integrates with Narwhal Extensions
  • 12
    Typescript makes it well integrated in vscode
  • 8
    Graphql support easy
  • 7
    Agnosticism
  • 5
    Easily integrate with others external extensions
  • 1
    Official courses
  • 149
    Powerful and handy
  • 134
    Easy setup
  • 128
    Java
  • 90
    Spring
  • 85
    Fast
  • 46
    Extensible
  • 37
    Lots of "off the shelf" functionalities
  • 32
    Cloud Solid
  • 26
    Caches well
  • 24
    Productive
  • 24
    Many receipes around for obscure features
  • 23
    Integrations with most other Java frameworks
  • 23
    Modular
  • 22
    Spring ecosystem is great
  • 21
    Auto-configuration
  • 21
    Fast Performance With Microservices
  • 18
    Community
  • 17
    Easy setup, Community Support, Solid for ERP apps
  • 15
    One-stop shop
  • 14
    Easy to parallelize
  • 14
    Cross-platform
  • 13
    Powerful 3rd party libraries and frameworks
  • 13
    Easy setup, good for build erp systems, well documented
  • 12
    Easy setup, Git Integration
  • 5
    It's so easier to start a project on spring
  • 4
    Kotlin
  • 1
    Microservice and Reactive Programming
  • 1
    The ability to integrate with the open source ecosystem

Sign up to add or upvote prosMake informed product decisions

Cons of NestJS
Cons of Spring Boot
  • 10
    Difficult to debug
  • 10
    User base is small. Less help on Stackoverflow
  • 5
    Angular-like architecture
  • 3
    Updates with breaking changes
  • 3
    Javascript
  • 1
    Frontend in backend
  • 1
    Unstable
  • 23
    Heavy weight
  • 18
    Annotation ceremony
  • 13
    Java
  • 11
    Many config files needed
  • 5
    Reactive
  • 4
    Excellent tools for cloud hosting, since 5.x
  • 1
    Java 😒😒

Sign up to add or upvote consMake informed product decisions

What is NestJS?

Nest is a framework for building efficient, scalable Node.js server-side applications. It uses progressive JavaScript, is built with TypeScript (preserves compatibility with pure JavaScript) and combines elements of OOP (Object Oriented Programming), FP (Functional Programming), and FRP (Functional Reactive Programming). Under the hood, Nest makes use of Express, but also, provides compatibility with a wide range of other libraries, like e.g. Fastify, allowing for easy use of the myriad third-party plugins which are available.

What is Spring Boot?

Spring Boot makes it easy to create stand-alone, production-grade Spring based Applications that you can "just run". We take an opinionated view of the Spring platform and third-party libraries so you can get started with minimum fuss. Most Spring Boot applications need very little Spring configuration.

Need advice about which tool to choose?Ask the StackShare community!

What companies use NestJS?
What companies use Spring Boot?
See which teams inside your own company are using NestJS or Spring Boot.
Sign up for StackShare EnterpriseLearn More

Sign up to get full access to all the companiesMake informed product decisions

What tools integrate with NestJS?
What tools integrate with Spring Boot?

Sign up to get full access to all the tool integrationsMake informed product decisions

Blog Posts

Vue.jsSpring BootUnity+7
2
1186
What are some alternatives to NestJS and Spring Boot?
AdonisJS
It is a Node.js Framework which is highly focused on developer ergonomics, stability and confidence.
FeathersJS
Feathers is a real-time, micro-service web framework for NodeJS that gives you control over your data via RESTful resources, sockets and flexible plug-ins.
Koa
Koa aims to be a smaller, more expressive, and more robust foundation for web applications and APIs. Through leveraging generators Koa allows you to ditch callbacks and greatly increase error-handling. Koa does not bundle any middleware.
LoopBack
A highly-extensible, open-source Node.js framework that enables you to create dynamic end-to-end REST APIs with little or no coding. Connect to multiple data sources, write business logic in Node.js, glue on top of your existing services and data, connect using JS, iOS & Android SDKs.
hapi
hapi is a simple to use configuration-centric framework with built-in support for input validation, caching, authentication, and other essential facilities for building web applications and services.
See all alternatives