Let’s say we don’t care about the backend<>frontend interconnection we see in most JS frameworks. We just want to program the backend. What would be the language of your choice?

  • Ephera@lemmy.ml
    link
    fedilink
    arrow-up
    3
    ·
    5 months ago

    I feel like you could’ve asked “what’s your favorite language?” and gotten the same responses. Like, it’s Rust for me. I could argue that because Lemmy is written in Rust, there’s already some mature libraries to work off of, but someone else could argue that for e.g. Ruby, too.

  • Paradoxvoid@aussie.zone
    link
    fedilink
    English
    arrow-up
    1
    ·
    5 months ago

    If I really hate front end, but still want a lot of the responsiveness of a SPA, I’d have to give ASP.NET Blazor a serious thought.

    It’s largely all back end driven, with the dynamic elements driven via webassembly that pretty much works like black magic.

  • Dojan@lemmy.world
    link
    fedilink
    arrow-up
    1
    ·
    5 months ago

    C#. Since I’m a .NET developer it’s the stack I’m most familiar with.

    Honestly I kind of like the idea of a front end with as little JS as possible.

  • farcaller@fstab.sh
    link
    fedilink
    arrow-up
    1
    ·
    5 months ago

    Any language you’re comfortable with is good for that. Ruby, JS, and Go come to mind the first because they all have solid ActivityPub libraries which are going to save you some time on interconnection. Any programming language can do static html.

  • nous@programming.dev
    link
    fedilink
    English
    arrow-up
    1
    ·
    5 months ago

    Whatever language you chose you might want to also look at the htmx JS library. It lets you write in your html snippets better interactivity without actually needing to write JS. It basically lets you do things like when you click on an element, it can make a request to your server and replace some other element with the contents your server responds with - all with attributes on HTML tags instead of writing JS. This lets you keep all the state on the backend and lets you write more backend logic without only relying on full page refreshes to update small sections of the page.

    For a backend language I would use rust as that is what I am most familiar with now and enjoy using the most. Most languages are adequate at serving backend code though so it is hard to go wrong with anything that you enjoy using. Though with rust I tend to find I have fewer issues when I deploy something as appose to other languages which can cause all sorts of runtime errors as they let you ignore the error paths by default.