7 ms·
What is the best typed language for back end web development?
After programming the backend for my current project in a non-typed language I never want to go that route again.
I think actually that the frontend project with all of its thousand of files and components is easier to handle just because typescript helps me so much.
- simantel 5y agoIf you're familiar with TypeScript, you could use it on the back-end as well, with Node and a build step or with Deno.
- _benj 5y agoIf you are familiar with it TypeScript could be a good choice. Language preferences are very personal but I personally like Golang. It's kind of like a "batteries included" language and deploying Go, which is copying a binary to a server is awesome!
- maattdd 5y agoIt's true if you don't have any other files such as HTML templates or CSS or whatever; which is fairly rare (don't even get my started on stuff like Packer which embed binary content inside the binary executable...). Nowadays, deploying any project should just be one docker build . away whatever the language.
- henhouse 5y agoIs the embedding necessarily a bad thing? I run a site entirely using Go templates and packr to embed the site’s files and it only adds a few MB. Latest version of Go has a built-in way to embed files now through a comment syntax.
- zkr 5y agoJava + Spring
- tofukid 5y agoI enjoy using Haskell, because of the type-safety, referential transparency, and stability of interfaces. I use Twain for HTTP server and routing + blaze-html for HTML + Selda for interfacing with SQL. I’ve built my last few projects this way (listed in my profile).
- maattdd 5y agoI like Crystal for this, the standard library has support for the most common stuff (HTTP server, JSON/XML parsing, logging, templating), installing additional packages is easy and the build step also. Nice bonus: the resulting app is native and fast.
- epimetheus2 5y agoScala3
- fgonzag 5y agoUnpopular opinion but... most of them are more than good enough. .net with C#, java (though I'd probably use kotlin), typescript, and go are the most popular ones and they will all do whatever you need with pretty great performance if written correctly. I'd do a simple CRUD app in all 4 of them and see which one I liked best from tooling to language design.
- aristofun 5y agoTypeScript is an amazing beast on backend as well
- k0t0n0 5y agoC# or java, if you are Node developer try TypeScript
- ttymck 5y agoIf you're serious about using the type system to encode business logic, improve resiliency, and reduce runtime errors: scala is really a great choice. Beware "type astronauts", FP purism, etc. and you'll be able to go very fast. You get access to the whole JVM ecosystem. Rust is great but more clunky. I'm under the impression F# is a viable alternative.
- Darmody 5y agoPHP declare(strict_types=1);
- JaggerJo 5y agoWe have great success with F# (both backend and frontend). Can’t recommend it enough.
- approxim8ion 5y agoI've been using TypeScript and quite like it.