News for hackers. Stuff that matters.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @08:17AM (#44040705)
Why would you use something other than a JS framework to build a web app back-end? You don't have to deal with OpenAPI or GraphQL, you can just use server actions.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by williamdclt on Tuesday May 20, 2025 @09:12AM (#44041227)
"server actions" seems to be a NextJS thing, not a JS thing? JS does not mean React and NextJS. The communication between frontend and backend is (almost) always HTTP, regardless of the languages and frameworks (server actions are http). Having a wrapper around HTTP isn't really a compelling reason to choose a technology for the very large majority of people: probably the opposite actually.

IDK what you mean by "deal with OpenAPI", OpenAPI is a spec not a technology like graphql.

In all honesty (and sorry for the directness), you don't really seem to understand these concepts and how relevant or not they are to this conversation

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @09:17AM (#44041265)
> server actions" seems to be a NextJS thing, not a JS thing?

It's a JS framework thing. Every mainstream JS framework has server actions or equivalent.

> Having a wrapper around HTTP isn't really a compelling reason to choose a technology for the very large majority of people: probably the opposite actually.

It is way more convenient to write a server action and be able to immediately use it in a client component than having to write an HTTP endpoint in a separate back-end project, and then regenerate your client via OpenAPI, or whatever else you use.

> IDK what you mean by "deal with OpenAPI"

I mean dealing with tooling to generate an HTTP client from OpenAPI schema.

> In all honesty (and sorry for the directness), you don't really seem to understand these concepts and how relevant or not they are to this conversation

Wrong

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by dboreham on Tuesday May 20, 2025 @12:18PM (#44043289)
Raising my hand with the opinion that you're wrong. Making it confusing as to whether code is executing on server or client is imho an antipattern.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @12:26PM (#44043374)
I’m wrong in what? Even if you’re confused whether server actions run on the server or on the client, it doesn’t take away benefits I listed before.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by williamdclt on Tuesday May 20, 2025 @12:44PM (#44043509)
> Every mainstream JS framework has server actions or equivalent

No. "Server actions" are a React concept, it has little to do with backend technology (the backend still speaks HTTP). This concept is completely irrelevant to most big frameworks like Express, NestJS, Koa, Hapi. Next is barely a "backend" framework: it's rather a React server framework that has a few basic backend functionalities.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @12:52PM (#44043575)
Okay, every full-stack JS framework.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by homebrewer on Tuesday May 20, 2025 @08:38AM (#44040893)
Better/scalable performance, actual runtime type checking without wrapping everything with third-party libraries and paying the associated overhead, talent pool in my area, better (or even existing) libraries for the task at hand, better observability instrumentation, personal preference... is this really an honest question?
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @08:45AM (#44040958)
> is this really an honest question?

Yes, there is nothing that works better than server actions. None of what you listed really makes sense to me. I have never had any runtime performance problems with TypeScript and wasn't JavaScript the most popular programming language in the world (the talent pool argument)?.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by diggan on Tuesday May 20, 2025 @08:20AM (#44040734)
Because there are other options available that might be better? Personally I'd chose Clojure for anything I have a choice with. Cargo culting a language like that does no one any favors.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @08:24AM (#44040774)
> Personally I'd chose Clojure for anything I have a choice with.

And then you would have to solve the problem of how to communicate with the client.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by diggan on Tuesday May 20, 2025 @08:25AM (#44040781)
I dunno, HTTP works pretty well for me as a transport layer to communicate with clients. Otherwise Websockets. Not sure why you'd think that be a difficult thing?
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @08:33AM (#44040844)
> Not sure why you'd think that be a difficult thing?

You aren't suggesting to handwrite an HTTP API client, right? You would have to set up either OpenAPI which is a mess, or GraphQL which is also a mess. LMK if you have a better solution.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by diggan on Tuesday May 20, 2025 @08:42AM (#44040930)
What exactly is the problem you're encountering when trying to interact with HTTP APIs? If you really want to use OpenAPI for whatever reason, there are plenty of ways of doing that even in Clojure/Java, so I'm sure it's possible in other languages as well. But it's not like using OpenAPI or GraphQL are the only two options, if you're of that opinion I'm afraid you've drank way too much of the koolaid.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @09:00AM (#44041085)
> What exactly is the problem you're encountering when trying to interact with HTTP APIs?

The problem is that, unlike when using server actions, when using HTTP APIs, there is nothing that automatically generates bindings.

> If you really want to use OpenAPI for whatever reason

No, I don't. But people use OpenAPI to avoid having to handwrite an HTTP client. This is especially relevant if you are developing a public API.

> But it's not like using OpenAPI or GraphQL are the only two options

What are other options?

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by diggan on Tuesday May 20, 2025 @09:34AM (#44041458)
> when using HTTP APIs, there is nothing that automatically generates bindings.

Is that really the biggest problem you face when programming? How many endpoints do you have? Even with projects with ~30 endpoints, it doesn't seem problematic to me, but maybe people regularly work on projects with 100s of endpoints, then it kind of makes sense. But I'm not sure that's typical enough.

> No, I don't. But people use OpenAPI to avoid having to handwrite an HTTP client. This is especially relevant if you are developing a public API.

People do a lot of stuff for a lot of nonsense reasons, doesn't mean that's the best way to approach things. The JS/TS ecosystem seems extra easy to fall into cargo culting too.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by floydnoel on Tuesday May 20, 2025 @09:32AM (#44041444)
"handwriting" an HTTP client is too much work for a developer? you need to import a library that does it for you? wow. abstraction at any cost, eh?
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @09:49AM (#44041667)
Yes, you have to waste time handwriting it and making sure that you actually wrote a proper binding. Then you also probably need to deal with API versioning. All of this goes away with server actions.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by coolcase on Tuesday May 20, 2025 @08:33AM (#44040845)
You don't need to deal with those anyway. RPC it. fetch one one end, route on other.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @08:36AM (#44040872)
> RPC it. fetch one one end, route on other.

What do you mean by this?

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by coolcase on Tuesday May 20, 2025 @03:57PM (#44045283)
JS fetch function in three browser.

Add a route on the back end.

RPC means just call it! don't worry about REST, GQL etc.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by liveoneggs on Tuesday May 20, 2025 @09:05AM (#44041153)
nextjs or bust? This is a wild take
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @09:07AM (#44041180)
Yep, Next.js has the best support for vibe coding.
Re:Reports of Deno's Demise Have Been Greatly Exaggerated by diggan on Tuesday May 20, 2025 @11:03AM (#44042436)
> vibe coding

"Vibe coding" as a concept is a fun joke, not a workflow you employ for doing serious engineering. It was a tiny experiment that somehow people thought was a suggested way of developing software, which obviously it isn't. Read the code yourself, otherwise it'll be really hard to call yourself any sort of engineer.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @11:09AM (#44042497)
> "Vibe coding" as a concept is a fun joke, not a workflow you employ for doing serious engineering.

Well I guess making Next.js apps isn't really "serious engineering"

> Read the code yourself, otherwise it'll be really hard to call yourself any sort of engineer.

I do read the code but I barely write any code by hand.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by diggan on Tuesday May 20, 2025 @11:15AM (#44042556)
> Well I guess making Next.js apps isn't really "serious engineering"

Where did I say that?

> I do read the code but I barely write any code by hand.

Right, so you use the words "vibe coding" yet you don't actually understand the concept? A lot of things make sense now. The description "vibe coding" is explicitly about "programming" with a LLM without reading or writing any code at all, for any purpose. If you read the code, you're not really vibe coding as originally described by Karpathy.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by koakuma-chan on Tuesday May 20, 2025 @11:23AM (#44042651)
> Where did I say that?

You replied to a comment that says "Yep, Next.js has the best support for vibe coding."

> Right, so you use the words "vibe coding" yet you don't actually understand the concept? A lot of things make sense now.

You can stop arguing that if one glances at the code one is no longer vibe coding, because in practice by looking at the code or even the LLM's thoughts you can catch things you don't want early.

Re:Reports of Deno's Demise Have Been Greatly Exaggerated by msie on Tuesday May 20, 2025 @09:03AM (#44041120)
Wow…