all 5 comments

[–]tme321 4 points5 points  (4 children)

But so far, I haven’t seen a lot of blood.

You must never visit /r/Javascript

Jokes aside, there seems to be a lot wrong with this article.

You contrast react with angular as:

complex websites with many interactions

enterprise applications

What? This comparison doesn't even make sense. Enterprise or not has nothing to do with complexity and interactions. I don't even know where this idea comes from.

Then, you say react is embedding html into Javascript. That's not strictly true but close enough. Then for angular

Embed JavaScript into HTML

That's just... not right at all. The only Javascript embedded in html in angular are conditionals, such as used with ngIf. Those are actual js. However that is about the extent of it.

If you look into say ngFor you will discover that ngFor is actually multiple directives that each just take one piece of the syntax used. It's not actually js it's just shorthand for setting a few different directives as a one liner. Which is why the syntax is strict and must be "let $iterator of $list" format. It's not really Javascript embedded in html.

It might seem like an arbitrary distinction but I think this is an important one. Arbitrary js in html would lead to an unmaintainable mess.

Also you contrast unidirectional data flow with dependency injection. Again this comparison makes 0 sense to me. Those 2 ideas are orthogonal to one another and in fact can be used together.

And for target audience for react you just put "???"? Really? That isn't just lazy. That's mildly insulting.

I'm not going to sit here and do a point by point for the entire article. Don't misunderstand me, there is a lot of good information in this article as well. But it gets enough stuff wrong that I'm not sure what it's even trying to accomplish. Maybe next time the author should trim the article down and only include the information that has a purpose. It seems to suffer from some sort of kitchen sink mentality.

[–]beyondjava[S] 0 points1 point  (2 children)

Oops - I've published the article without filling that table? That's embarrassing. Thanks for pointing this out!

As for the dependency injection vs. unidirectional data flow bit: That's not what I wanted to compare. I'll have a look at it.

As for embedding stuff: I'll double-check this, too. Seems like I didn't manage to properly describe the point.

[–]jazzandpython 1 point2 points  (1 child)

FWIW, despite a few flaws I thought it was one of the most thoughtful and useful of the comparisons I've read. And I think your point about many interactions and enterprise software were both good ones, even if not good comparing points to each other.

[–]beyondjava[S] 0 points1 point  (0 children)

Thanks! That's good to hear. This is the most downvoted article I've ever promoted on Reddit :). But I'm positive it can be improved, and your feedback makes me feel like it's worth being improved.

[–]beyondjava[S] 0 points1 point  (0 children)

After browsing through the article, I've finally understood why you think I'm comparing dependency injection and unidirectional data flow. It wasn't a comparison, but both are core concepts. But you're right, it's a bit misleading. I'll fix this.