News for hackers. Stuff that matters.
Re:Go with PHP by keyle on Thursday May 11, 2023 @12:26AM (#35897478)
Most of the stuff we do now we do with "Laravel Livewire".

It's quite brilliant really, even for modals etc. "look ma, no javascript!". Of course it does JS for you, you just don't see it. That's my favourite kind of Javascript - someone else's problem. Livewire is a mid-way between front-end backend, it's a progressive back-end with long polling like NextJS I suppose. From your end though, it takes care of all the security of running your own API, and correctness. You basically have dynamic front-end from the backend.

If you want a full SPA or you need an application that is very responsive without network requests, I recommend VueJS - Livewire recommends AlpineJS, but of course you might be a React guy, that's fine, and use Laravel as a regular API.

You can even use GraphQL if you want to die of a young age, have some weird kinky thing going or you have something to prove... Unless you're Facebook of course you probably don't need GraphQL.

Re:Go with PHP by kaba0 on Thursday May 11, 2023 @02:22AM (#35898396)
> it's a progressive back-end with long polling like NextJS I suppose

It’s kind of funny that this is the new best thing, when this is almost the same model JSF did decades ago.

Re:Go with PHP by robertlagrant on Thursday May 11, 2023 @07:46AM (#35900800)
It just had so many other issues with its ergonomics that this nice innovation was lost in the weeds a bit.
Re:Go with PHP by kaba0 on Thursday May 11, 2023 @07:54AM (#35900874)
That I agree with, though I found that for internal admin pages with many forms, there was nothing more productive.
Re:Go with PHP by robertlagrant on Thursday May 11, 2023 @08:02AM (#35900939)
I actually used a product that built on top of it, so my experience is probably worse than yours!