3 ms·
I've been using the app/ dir for a couple months now on a side project and I'm really liking how concisely I can build UI + backend + deployment. Vercel is gett
by reducesuffering 4y ago
I've been using the app/ dir for a couple months now on a side project and I'm really liking how concisely I can build UI + backend + deployment. Vercel is getting some heat for it's pricing, but Next.js is really pushing forward what's possible for people without fiddling with DevOps, separate frontend deployment, separate backend deployment, etc. Coming from Django with Create React App, Django Rest Framework, on a VPS, is a relative nightmare compared to Next.
For example, in one small file, two functions, you have a reactive UI, styling (Tailwind), backend with database fetching, routing, and deployment handled:
async function getPostsFromDb() {
return await prisma.posts.findMany();
}
export default async function PostsPage() {
const posts= await getPostsFromDb();
return (
<main className="flex min-h-screen flex-col items-center justify-center">
{posts.map((post) => {
return (
<GradientCard
key={post.name}
title={post.name}
/>
);
})}
</main>
);
}
- benatkin 4y agoTheir pricing seems OK to me, the only issue I have is that you can't tell them just to shut it down if the bill goes past a certain limit.
- CharlieDigital 4y ago> ...in one small file, two functions, you have a reactive UI, styling (Tailwind), backend with database fetching, routing, and deployment handled Sounds like a recipe for spaghetti. Other platforms have been here before (ASP.NET Web Forms comes to mind) and it always ends up bad.