Mern stack Or Nextjs ?

I have a question in which case I have to use mern stack, and in which case I have to use nextjs? And i know nextjs well should i learn mern stack too??
16 Replies
bruno!
bruno!2y ago
if you're mostly talking about having a standalone server vs using api routes, I think it depends on how much complexity your backend needs and if your project is able to run in a serverless environment
Pranoy
PranoyOP2y ago
Actually i wanna master react by making projects so what will be best option?
bruno!
bruno!2y ago
NextJS currently NextJS is the framework with the best integration with server components, and right now server components, and server actions coming soon, are becoming a big part of react, so if you want to master it, it makes sense to a framework where you can apply it's concepts but if you want to go really deep, eventually you can even setup your own node server with ssr, server components, etc
Pranoy
PranoyOP2y ago
Alright thanks 🙏 i understood I'll go with nextjs
m$
m$2y ago
Hobby project or actual client/job work? @Pranoy Depends on so many things... Go with MERN, understand the separation between your technology, then come back to Next and see what problems it solves and then you have something to compare it to
Pranoy
PranoyOP2y ago
I'm in class 12 in commerce stream, and i know normal React, hooks, class/func components, and i know specially backend in django, fastapi, but I'm seeing that there is better job opportunities in nodejs, so I'm confused what should I use to make my Own projects which i can show in my portfolio so I'll get a good job, and clients projects
m$
m$2y ago
Flip a coin and go with either IMO build to learn for the job listings and also your own curiosity with new technologies Disagree lol
_hellomoto534
_hellomoto5342y ago
mern is just db-Mongo routes-Express frontend-React backend-NodeJS
Pranoy
PranoyOP2y ago
Alr so in simple: If i wanna learn the concept, how react works i have to use mern If I'm going to production i have to use nextjs Am I correct? @RobotSail also i have one more doubt, i saw many devs use mern stack to build their projects like E-commerce, Job Portal, Blog, that's good, but while nextjs has alot of features than mern like SSR, comfortable with serverless, easy deployment, good community support, why they go with MERN stack for their personal projects?? Isn't nextjs is better option for them in these projects Alr thanks i understood
m79z
m79z2y ago
Use NextJS V12, using NextJS 13 is optional, many companies are still using v12. Also prefer TypeScript over JavaScript if you can.
_hellomoto534
_hellomoto5342y ago
next means you stuck with one backend . mern or nodeJS is very easy to reconfigure to nestjs or any other backend.
bruno!
bruno!2y ago
in this case you can go with MERN using nextjs on the react side, so you can improve both on nodejs and react initially I thought the focus were only mastering react, so in that case going with nextjs solely would be better using MERN with vite, which is what’s recommended and you still won’t need to learn bundling
Pranoy
PranoyOP2y ago
Yes, i am actually a backend developer and only know python frameworks such as django, fastapi, but i want to learn and master the nodejs, reactjs that's what I wanna do thanks you 😇 I only use typescript, and i also understand the v13 app router so that's why I'm using it, btw thanks for sharing
bruno!
bruno!2y ago
I still think using vite is like using cra, you’re using a bundler but you don’t need to care about it
Choco
Choco2y ago
As i know nobody uses raw react at this moment, so why not like use next.js and back-end express/nest
Zan
Zan2y ago
I would argue most people using React do not use a metaframework, the mature ones are still very new and most React projects >2yo are using SPA with webpack/vite
Want results from more Discord servers?
Add your server