Shawn Wildermuth's Rants and Raves

Thanks for visiting my blog! See more about me here: About Me

Angular v. React v. Aurelia v. et al.
Angular v. React v. Aurelia v. et al.
September 1, 2015

When I announced my upcoming course, I had a lot of people ask me about what I thought of X framework versus Angular (which I’m covering in the course). I feel like I have to say something.

Before I bestow my blessing, let’s talk about the fundamental problem of frameworks in general. They can be a boon or a bust and many developers have been hurt by a selection of a specific framework in the past. I know I’m being asked so that some devs can go to their architect to confirm their particular positions. I’m hoping to avoid that in this post, but I doubt it will work.

Fallacy of the Perfect Framework

This selection of a framework isn’t new. It’s ancient in fact. I had to battle the same problem in my past; whether it was Oracle v. SQL Server in my ADOGuy days, MVVMLight vs ever other MVVM library in Silverlight, or even Mongo v. every other NoSQL Store. The argument is the same:

“I don’t want to make a mistake by picking the wrong framework.”

The problem is that software project rarely fail because of the framework. How many successful PHP, Web Forms, and even Perl+CGI websites exist (a ton of them). By trying to find the perfect framework you’re just delaying the eventual decision.

Frameworks like these are often more a matter of preferences and work styles than actual functionality or speed.

Pick a Horse and Ride It until it’s the Wrong Horse

So what do I suggest? Pick a horse and ride it hard. Find the edges that don’t make you happy and pivot. Yeah….pivot. We stress that we are Agile in development but only when it comes to stand-up meetings and sprints. How about change your mind once in a while. If the framework (or any other part of your dev stack) isn’t working, find a better solution. But only find a better solution if you really have great reasons for it.

Stop Being Fanbois (Fangyrls?)

Be critical of your choice of framework. There is a phrase I like from fiction writing. “Don’t be afraid to kill your darlings.” It’s used in fiction to say that you have to be able to kill off characters.

In development, our darlings are our technical decisions. Unfortunately as developers we’re more apt to protect our darlings. When we pick a framework, we end of defending it instead of being honest about the tradeoffs you made in picking it. Own that. Be a critic and still use it. When you know the dark corners of a framework, you know how to avoid them.

“But there wouldn’t be dark corners if it was the ‘right’ framework, right?”

Nope.

Every framework is an exercise in trade-offs. No piece of code can be awesome at everything. Doesn’t happen.

Nope.

My Choice

So I’ve been using AngularJS 1.x (and 2.0 in some testing) for a while. Why did I pick this darling? I wanted a complete framework (before Angular, it was more like Knockout + Sammy + Plugins). AngularJS fit the bill and had a style that meshed with the way I like to write server-side code. Testable, componentized, and not over-engineered (as far as I am concerned). That’s the horse I’ve picked for now.

This doesn’t mean I’ve avoided looking at other projects. I’ve done some very summary playing with React, Aurelia, Comet, etc.  But nothing in these projects has blown me away enough to change course.  If you love React or Aurelia…awesome. Your project is likely in good hands.

I’m burying this in the last part of the post because I don’t think it’s actually that important, but some of you want to know why I didn’t like other frameworks so here goes.

React: Too much ceremony and JSX makes me feel dirty. It feels wrong to me. (Note, *I* feel dirty, it doesn’t mean it’s bad. I just don’t care for it).

Aurelia: I like his approach. I should, it’s a lot like Angular 2.0. My real issue here is that the Durandal people like to write frameworks. I feel like they finish a framework and then try and create a new one to fix the decisions they made in the last one (going way back to some Silverlight frameworks they were responsible for). This is even seen in their home page. It shows Aurelia, Durandal and a new unnamed framework project. I don’t like the churn.

So for me, Angular 1.x and 2.0 are my future for now. I like where it’s headed and I like the team. That’s enough for me.

I am sure you all have your opinions and I will approval pro and con comments as long as they aren’t abusive. Promise.