Ask HN: What would be your stack if you are building an MVP today?
459 pointsSpecifically the backend. I'd love to hear your reasons. Do you keep one eye on what the stack would be post MVP?
1. Old schoolish (VPS - Maybe DO, Django/Flask/Rails/Remix/Next with postgres)
2. Supabase etc with JS/TS on either side of the network
3. Lambda/Cloud functions with Firebase/Dyanamo DB/Cosmos DB etc
4..n. What else and why?
Comments (723) 347 threads
Earlier commentsI went with:
Terraformed AWS/EKS
Docker
Postgres
Node/Express
React
I'm pretty language agnostic, but for webstack I like to use Node, because it means I don't have to context switch too hard. I'm using the same language on the frontend and backend with the same APIs. I only have to keep one standard library in my head and a lot of packages are compatible with either front or backend.
Whenever I'm working on the web, that's going to be my go to.
I would consider Typescript, but I don't think the cost/benefit of Typescript really balances out until you have a team. The need to create types and type harnesses for libraries slows you down at first, and speed is the name of the game with an MVP.
You are still going to have to make a lot of correct library decisions to implement key features like auth and a DAL. Nest JS is an interesting batteries included approach (haven't tried). TypeORM had a lot of issues few years ago but might be getter better.
Disagree re: TypeScript though. Most libraries worth using have types or are TS native these days. I find myself much more productive writing TS on solo projects with less foot gunning.
I'd say either CGI scripts, PHP, or Ruby and sqlite as a DB, all hosted on a single VPS. That'll get you plenty far and be easy to grow out of.
I'm constantly tempted by Phoenix but desuaded by the lack of a type system. Does elixir somehow make up for the lack of types as a functional language? Also, I can reuse a good deal from my current stack in a react-native app for mobile, which I'd miss out on in another framework.
Wish I could say Flutter, but have not been impressed by the web experience.
I've mainly used sinatra and rails for Web apps and always found it difficult to define a clear api on which the frontend was based on (I.e in order later to build ios or android apps off).
Using Node-Red forced me to build an api for the frontend, the frontend has no direct contact with postgres.
Plus I found it to be more flexible than directly coding when I wasn't even sure what the database schema would look like.
Database modelling was done with pgModeler, I.e. No migrations and more pgsql functions and triggers.
What I use it for is api endpoint, email templates and sending emails, websockets and as admin tool (the dashboard).
It requires a lot of discipline to keep the flows separate. Reuse of code is a challenge (very tempting just to copy and paste code) and generally to maintaining an overview (simply because of the number of flows).
On the other hand, business people can immediately see the flows and thereby understand the logic. Debugging is a matter of connecting a debug node at any point in flow. Background jobs (ie sending email) is a matter of splitting the output of a node (ie http response is sent and at the same time email is triggered or websocket update is sent).
Scalability and production performance remains an open question for me. In worse case scenario it would be a case of taking the flow.json (my entire backend is a 300k json) and building some kind of interpretor from scratch ;)
NodeRed is a perfect MVP for serverless without all the cruft and costs of AWS/GCP/Azure/whatever.
All comments shown.
Couldn't load more comments. Check your connection and try again.