AstonJ

AstonJ

This is the Future of Webdev. Crazy, Right?

This was posted on the Elixir Forum and thought it was worth sharing here!

I love how the excitement of the author shines through and I think it does a great job highlighting the benefits of functional programming, Erlang/Elixir and Phoenix LiveView!

I’d be especially keen to hear what those of you who are using OOP languages think, and whether it’s enticed you to look at Elixir :sunglasses:

Most Liked

OvermindDL1

OvermindDL1

NaN === NaN; // -> false

This is actually correct, in any language. As per the floating point spec NaN equals nothing, not even itself. To return anything else would be failing the spec, so this is correct, not a javascript’ism (which has plenty of broken things to choose from).

As much as I want to agree with most of the article, it comes off a bit… high and mighty, and there are definitely some issues, like the fact it’s trying to go back to the ol’ RPC style calls from the long past.

And you don’t need immutability, you need either safe or no aliasing, which yes means you need immutability in most languages, but in languages like Rust you don’t, it has safe aliasing, even mutably, which means you can have both performance and safety of code where pure immutability has overhead you can’t get rid of. Pure functions are good though, to make a function impure in rust means you have to touch unsafe or something wrapping unsafe, lol, and of course without the aliasing issues then it’s safe to do as long as the unsafe code is written safe.

The Erlang VM is awesome though, especially as an orchestrational glue between parts written in native fast languages like rust. Rust can do what the Erlang VM does for its actor stuff, but it doesn’t have a great pattern for Erlang VM’s multi-node, not to say you can’t do it, just takes a lot more work.

Phoenix LiveView is just the old made new again, definitely harkens back to my Wt and N2o and such days, useful style to program pages in for server-driven code. ^.^

Phoenix channels are such a fascinating abstraction that even Rocket.rs is copying it, same names and terminology, lol.

SPA’s do still have their place however, especially if the client need to do a lot of its own calculations or little to no server communication or if it needs to run offline. It would be awesome to support both static, server side dynamic, (LiveView) and client-side dynamic (SPA) all in the same codebase though.

AstonJ

AstonJ

It’s always interesting to hear your thoughts ODL :blush:

I always think of Erlang/Elixir being the ‘brains’ of an app - basically co-ordinating everything else (like the muscle :joy:) however it’s great that you can get really far with Elixir itself (particularly with things like Phoenix and LiveView) :sunglasses:

Ah that’s interesting! A great indication that Phoenix got it right :smiley:

Rust is definitely cool - and so interesting! I can’t wait to start learning it, and I do wonder whether you should write a book about it one day!? Maybe even if it’s a Rust for Beginners or Get Started With Rust book that can be read before other books? :nerd_face:

OvermindDL1

OvermindDL1

If you ever have some time to burn I still recommend reading The Official Rust Book, lol. It’s just a bit of a crash course, the reference guide and docs are more comprehensive. of course ^.^

Popular Backend topics Top

PragmaticBookshelf
The next step in the evolution of user interfaces is here. Chatbots let your users interact with your service in their own natural langua...
New
New
New
PragmaticBookshelf
Learn different ways of writing concurrent code in Elixir and increase your application's performance, without sacrificing scalability or...
New
ohm
Does anybody have good learning resources with regards to going into Event Driven Design, Architecture or Sourcing? I got recommended Er...
New
AstonJ
More cool tech inspired by <span class="hashtag-icon-placeholder"></span>erlang :nerd_face: By combining the fault-tolerance and massiv...
New
mafinar
I did not add this to a “this weekend I’ll learn” like my few other journals as I am decided on using this in the long term. Last I work...
New
PragmaticBookshelf
Use WebRTC to build web applications that stream media and data in real time directly from one user to another, all in the browser. ...
New
ManningBooks
Spring Security in Action, Second Edition is a revised version of the bestselling original, fully updated for Spring Boot 3 and Oauth2/Op...
New
First poster: bot
Node.js v18.16.0 has been released. Link: Release 2023-04-12, Version 18.16.0 'Hydrogen' (LTS), @danielleadams · nodejs/node · GitHub
New

Other popular topics Top

PragmaticBookshelf
A PragProg Hero’s Journey with Brian P. Hogan @bphogan Have you ever worried that your only legacy will be in the form of legacy...
New
Exadra37
I am thinking in building or buy a desktop computer for programing, both professionally and on my free time, and my choice of OS is Linux...
New
brentjanderson
Bought the Moonlander mechanical keyboard. Cherry Brown MX switches. Arms and wrists have been hurting enough that it’s time I did someth...
New
AstonJ
Curious to know which languages and frameworks you’re all thinking about learning next :upside_down_face: Perhaps if there’s enough peop...
New
PragmaticBookshelf
Rust is an exciting new programming language combining the power of C with memory safety, fearless concurrency, and productivity boosters...
New
AstonJ
Just done a fresh install of macOS Big Sur and on installing Erlang I am getting: asdf install erlang 23.1.2 Configure failed. checking ...
New
gagan7995
API 4 Path: /user/following/ Method: GET Description: Returns the list of all names of people whom the user follows Response [ { ...
New
First poster: joeb
The File System Access API with Origin Private File System. WebKit supports new API that makes it possible for web apps to create, open,...
New
First poster: bot
The overengineered Solution to my Pigeon Problem. TL;DR: I built a wifi-equipped water gun to shoot the pigeons on my balcony, controlle...
New
PragmaticBookshelf
Author Spotlight Rebecca Skinner @RebeccaSkinner Welcome to our latest author spotlight, where we sit down with Rebecca Skinner, auth...
New