News for hackers. Stuff that matters.
Re:Angular 4.0.0 Now Available by ssijak on Friday March 24, 2017 @07:37AM (#13948216)
Hmm. I see that Angular is getting aaaaalot of hate here. I really tried to understand why but have not found really valid reasons, just preferences. I have used Angular 1.x a lot and have just tried Angular 2. It really enables me (somebody who comes from primarily strong backend dev experience) to work on frontend SPA apps productively and fast.

It does not 'feel' heavyweight or that it gets in my way too much, but the contrary is true. Of course, it has it`s quirks, as every larger lib have, but it`s pluses outweigh minuses by far for me.

Preferences aside, does Angular make you less productive than other options? Do you feel that you fight the framework? Can you finish non trivial frontend apps, involving 5+ team members, 'better', with cleaner code and much faster with other options?

This are just honest questions. I wanted to start some pet project in angular2 soon, but would listen to alternatives, maybe it is a right moment to try some of them.

Re:Angular 4.0.0 Now Available by danielpatrick on Friday March 24, 2017 @07:57AM (#13948293)
I've been using Angular 2 for a medium sized application that will be going into production within the next few weeks. I'm not affiliated with the Angular team at all.

I started using it when this app was very much a POC last summer, just as the Angular team was finishing up the 2.0 release.

I learned firsthand last summer the issues with using a framework that was still in the oven: constant updates and some dependency changes. That was no fun for some time.

But I'll say now that it was worth it. (Maybe I should have started a little later, post-2.0 release). But I'm now building out a decent sized and complex application much faster than I'd ever done before.

It is strongly typed, it is modular, and it has dependency injection. Oh and it's strongly typed. I can't emphasize the importance of this enough. I know you can use typescript without Angular, but that the Angular community and the docs are all in typescript make this a typescript-native framework.

I'll never look at JavaScript again if I don't have to. You and your IDE and the rest of your team can know an object's Type without having to scrounge around, it's such a blissful departure from JavaScript.

It definitely has a learning curve. If you're spinning up a simple web app it may or may not be for you. (...though now I use it to spin up simple web apps because I'm used to it and it's so good for that) But for anything complex that is being worked on across a team, I recommend you take the time to learn it.

It's not perfect, nothing is. But it is leagues ahead of any framework I've used on the front end. And having gone to Typescript, I will never use a native JavaScript framework again.

Re:Angular 4.0.0 Now Available by alttab on Friday March 24, 2017 @09:09AM (#13948645)
What's been your experience with browser-side debugging? The one thing that scares me about typescript is you end up debugging something you didn't write.
Re:Angular 4.0.0 Now Available by danielpatrick on Friday March 24, 2017 @09:24AM (#13948727)
Yes, good question.

I use VS Code (with the Chrome debugger plugin) and that works like a charm. I don't debug javascript in the browser anymore.

TS provides source mappings to map the compiled javascript back to the source (similar to a .dll's .pdb maybe?).

It took me some time to set up the config file which proved to be a headache (because webpack was screwing with the source maps), but again once that was set up it has been a breeze to debug right in my IDE whenever I want.

Re:Angular 4.0.0 Now Available by leshow on Friday March 24, 2017 @03:08PM (#13951393)
Odd, I'm new to vscode, but I tried to set up this plugin and it was completely unusable to me.

Perhaps you can describe the steps you followed? I tried installing the plugin and launching chrome with the debug flag, then setting a breakpoint in vscode. Is there something I am missing there?

Re:Angular 4.0.0 Now Available by kevindqc on Friday March 24, 2017 @12:44PM (#13950197)
That's been my experience too. Also once angular-cli seems more stable, I will probably switch to it and delete webpack (I know angular-cli uses webpack behind-the-scene, but at least I don't have to deal with it directly)
Re:Angular 4.0.0 Now Available by kamarg on Friday March 24, 2017 @09:18AM (#13948683)
You can tell the Typescript compiler to generate source maps that allow you to debug your Typescript code in the browser with a single configuration item in tsconfig.json. Chrome (and maybe Firefox?) will download them by default when you open up the debugger.
Re:Angular 4.0.0 Now Available by jmcmichael on Friday March 24, 2017 @12:06PM (#13949860)
By default angular-cli produces source maps in dev mode. These work transparently when viewing source and using breakpoints in Chrome, Firefox, Safari, Opera. Just install @angular/cli create a project and a few components and check it out: https://github.com/angular/angular-cli
Re:Angular 4.0.0 Now Available by vog on Friday March 24, 2017 @09:29AM (#13948751)
That's why I'd personally prefer Flow for that. It has a more elaborate type system anyway. [1]

Moreover, Flow is pure annotation, which can be removed by Babel. And Flow is also backed by a large company (Facebook instead of Microsoft).

However, if you do want to generate JS, use a language that elminiates runtime errors almost completely, such as Elm or OCaml (through bucklescript or js-of-ocaml).

[1] The following presentation contains some scary examples of incorrect code not rejected by Typescript. I'd rather prefer Flow which errs on beeing too strict: https://djcordhose.github.io/flow-vs-typescript/elm-flow-typ...

Re:Angular 4.0.0 Now Available by throwasehasdwi on Friday March 24, 2017 @10:42AM (#13949173)
Your comment neglects to mention that Typescript debugging is generally easy because one of the design goals of typescript is to produce javascript that matches what a developer would write.

Debugging javascript produced by Babel is generally hell in comparison. The transforms done by Babel are not designed to be human readable and they generally aren't.

Re:Angular 4.0.0 Now Available by vog on Friday March 24, 2017 @11:01AM (#13949328)
Whoops, you are right. Removed the misleading part of my comment.
Re:Angular 4.0.0 Now Available by coldtea on Friday March 24, 2017 @08:29PM (#13953351)
>And Flow is also backed by a large company (Facebook instead of Microsoft).

Only Facebook doesn't care much to back or promote Flow, besides the occasional blog post, whereas Microsoft has created a whole IDE / VS Code support for it, great tooling, documentation, etc.

Re:Angular 4.0.0 Now Available by wincy on Friday March 24, 2017 @09:19AM (#13948689)
At least in Chrome it'll pick up the mappings and let you directly debug the typescript you wrote. Worst case the javascript isn't nearly as gnarly as you'd think.
Re:Angular 4.0.0 Now Available by alttab on Friday March 24, 2017 @03:18PM (#13951468)
But then you need to be good at Typescript, React, AND Javascript to build a feature. And that's not even considering databases, server middle ware, etc.
Re:Angular 4.0.0 Now Available by hacktothefuture on Friday March 24, 2017 @09:12AM (#13948661)
Great question. This is a cause for concern for me as well.
Re:Angular 4.0.0 Now Available by jondubois on Friday March 24, 2017 @09:57AM (#13948916)
I don't particularly like TypeScript. It slows me down because of several reasons:

- Compile time means that it takes more time to debug anything.

- The rigid interfaces mean that I need to spend more time researching how to use various modules/libraries (maybe code completion would offset this problem but this is only possible with a heavy IDE that has intellisense or similar - Not Atom).

- When I want to test something quickly, I often get annoying compile-time errors along the lines of 'code is unreachable...' among others.

- It requires more planning to do anything (since you have to design the interfaces before you can start to implement). This is also not good if you just want to try something quickly and then roll back later.

- Changes to one class/interface tend to have a large cascading effect on other classes/interfaces so it takes more time to make changes to code - This happens with JS too but to a much lesser extent.

- Adds lots of unnecessary dependencies to my project.

- Complicates setup and DevOps tasks, Dockerizing, (E.g. due to version mismatches and thousands of other potential issues) etc...

The reason why I don't like heavy IDEs is because:

- They're slow and clunky (sometimes they freeze for a long time in order to index content)

- The use up a ton of memory.

- They make your team lazy when it comes to structuring your source code into proper folders (since you start to rely more on search features of the IDE to find things).

- They take ages to install.

- Support fewer operating systems.

- Are usually proprietary and difficult to customize.

- More prone to bugs.

Re:Angular 4.0.0 Now Available by throwasehasdwi on Friday March 24, 2017 @10:39AM (#13949156)
Your complaints against "heavy" IDE's don't make sense. All of the points you made either aren't valid or don't matter.

- They're slow and clunky Not anything I've used. Eclipse and Visual Studio run nice and smooth on a decent machine.

- The use up a ton of memory. Who cares. Slack and anything based on electron uses hundreds of megabytes. Chrome regularly uses gigs. Most of the IDE's I use take less than 500 megabytes of ram, even phones have plenty.

- They make your team lazy when it comes to structuring your source code into proper folders Absolutely not. Your reasoning is that making things easier = making code worse. The IDE you use has nothing to do with your dev culture

- They take ages to install. Some of them do, notably Visual Studio. All the other ones I've used just take a few minutes. Also, who cares??? You only have to install it once, what is 5 minutes for an app you're going to use for thousands of hours???

- Support fewer operating systems. No. IDE's based on java run on almost anything. Again I think you're speaking from the experience of using visual studio.

- Are usually proprietary and difficult to customize. Also no. Every IDE I've used supports plugins and an unholy amount of configuration options. Every IDE I use is open source, again except visual studio.

- More prone to bugs. What? Why? How?

Re:Angular 4.0.0 Now Available by tukelully on Friday March 24, 2017 @01:02PM (#13950367)
Alot of these things do matter and it seems to me like all you're doing here is excusing bloat via hyperbole. I don't even agree necessarily with a lot of the parent comment, but I disagree with yours.
Re:Angular 4.0.0 Now Available by coldtea on Friday March 24, 2017 @08:29PM (#13953354)
>The rigid interfaces mean that I need to spend more time researching how to use various modules/libraries

Why, otherwise you'd just throw random parameters in a module's functions and see what sticks?

>Compile time means that it takes more time to debug anything.

Most people compile their JS anyway, TS or not, with Babel et al.

>maybe code completion would offset this problem but this is only possible with a heavy IDE that has intellisense or similar - Not Atom

VS Code has code completion for TS and is similar to Atom. And even Sublime Text has code completion for TS (based on tools MS itself provides for "intellisense" style predictions).

>- It requires more planning to do anything (since you have to design the interfaces before you can start to implement). This is also not good if you just want to try something quickly and then roll back later

Doesn't make any sense. It's not as if you don't need to know the interfaces before you start to implement with regular js. Only there you need to hunt for the documentation to tell you what's expected to pass -- instead of seeing what the types are directly (e.g. with intellisense).

>- Changes to one class/interface tend to have a large cascading effect on other classes/interfaces so it takes more time to make changes to code - This happens with JS too but to a much lesser extent.

It happens to the exact same extend in JS. Only with TS you are shown where the problems are automatically, with JS you have to hunt those places or discover it at runtime.

The rest goes downhill...

Re:Angular 4.0.0 Now Available by superninja234 on Friday March 24, 2017 @10:15AM (#13949007)
"It requires more planning to do anything. This is also not good if you just want to try something quickly and then roll back later."

Since you can pretty much type javascript in to a TS file and it will work I don't see this being valid.

Also planning is good, if your not thinking about the structure of your code (which does not take that long) then your just producing diarrhea.

Re:Angular 4.0.0 Now Available by merb on Friday March 24, 2017 @10:58AM (#13949312)
> - Compile time means that it takes more time to debug anything.

how can this be an issue? even javascript needs to be concated minified and whatever to take it into production. it's not like that any human writes minified and mangled javascript with direct gzip.

P.S.: I'm not a fan of TypeScript. But to say you need to compile it, is just an excuse.

Re:Angular 4.0.0 Now Available by WorldMaker on Friday March 24, 2017 @12:11PM (#13949895)
The Typescript compiler is also happy to run directly inside the browser because it is itself written in JS. I've debugged projects where the TS is compiled at runtime inside the browser and F5 refresh is the entire build process.

Though it's just as easy to use a good IDE's build button (VSCode Ctrl+Shift+B for instance) or TS works well as a watch process that watches for saves and compiles them when you save.

Re:Angular 4.0.0 Now Available by leshow on Friday March 24, 2017 @03:14PM (#13951440)
> - It requires more planning to do anything

That's the idea. You think about what you're going to write in a strongly typed language rather than just throwing stuff at the wall hoping that something will stick.

> - The rigid interfaces mean that I need to spend more time researching how to use various modules/libraries

I don't understand this. In one case you have an API where the types of all the functions is available, so you can see almost right away how to use it. In the other case you have to rely on someone providing you really good documentation OR you read the implementation.

> - Changes to one class/interface tend to have a large cascading effect on other classes/interfaces so it takes more time to make changes to code - This happens with JS too but to a much lesser extent.

It's either you find the error at compile time or at run time. Don't kid yourself, there's a 'cascading effect' in both typed and untyped codebases, just in the typed one the compiler will help you find errors.

Granted, I'm not the biggest TS fan, I'd take Elm or Purescript, or even Flow. But your gripes seem to be directed to typed languages in general.

Re:Angular 4.0.0 Now Available by jondubois on Friday March 24, 2017 @04:42PM (#13952065)
>> - It requires more planning to do anything

> That's the idea. You think about what you're going to write in a strongly typed language rather than just throwing stuff at the wall hoping that something will stick.

I think this is a valid point for developers who only have a few years of experience but I've been coding professionally for over a decade now - I don't need the compiler to artificially slow me down - I'd rather spend my mental energy thinking about the algorithm/architecture in its purest form without getting caught up in trying to satisfy the compiler's tedious requirements.

For me programming in a typed language is like using software that always asks you "are you sure you want to do this?" every time you tell it to do something. It's OK if you're a beginner, but I just find it frustrating.

I spent many years programming in ActionScript 3 and then Java so I feel like I've given typed languages a fair shot.

Re:Angular 4.0.0 Now Available by leshow on Saturday March 25, 2017 @12:41PM (#13956404)
> I don't need the compiler to artificially slow me down

It's slowing you down because you've written code with errors. Those type errors are still in your dynamic code, you just can't see them.

> I spent many years programming in ActionScript 3 and then Java so I feel like I've given typed languages a fair shot.

I don't think you have, you've missed many wonderful modern type system features.

Algebraic types, for one, aren't present in either of those languages and are massively useful, replacing 'null' (with a type like Option/Maybe) and exceptions (with a Result/Either concept) in many languages that have them.

Not to mention, with a language that has type inference, you don't even have to write the type in many cases, and yet you keep the guarantees of a strongly typed language.

Re:Angular 4.0.0 Now Available by coldtea on Friday March 24, 2017 @08:36PM (#13953378)
>I think this is a valid point for developers who only have a few years of experience but I've been coding professionally for over a decade now - I don't need the compiler to artificially slow me down

You'd be surprised.

There's a reason that developers after decades of dynamic languages turn increasingly to types (of which Flow and TS are examples in the JS world).

Re:Angular 4.0.0 Now Available by lilactown on Friday March 24, 2017 @11:44AM (#13949663)
VS Code (equivalent to Atom in power and scope) has the best intellisense for typescript. I use it over full-fledged IDEs (Intellij IDEA) all the time.
Re:Angular 4.0.0 Now Available by danielpatrick on Friday March 24, 2017 @02:46PM (#13951208)
> The rigid interfaces mean that I need to spend more time researching how to use various modules/libraries (maybe code completion would offset this problem but this is only possible with a heavy IDE that has intellisense or similar - Not Atom).

Obviously, to each his own.

I'd encourage you try Typescript again though. Your given reason doesn't make much sense. Regardless of whether the language is strongly typed or weakly typed, you still need to use modules and libraries correctly. "Not having to research" means you're just going to end up throwing data at a library without knowing what it's expecting. The research has to happen in both scenarios, but with typed languages it's easier. The research is just in the code already. (Try VS Code, not a "heavy" IDE by any means, but it has native support for TS code completion.)

If I have any modular interface, you need to know what to pass me. If you're receiving data from me, you need to know the structure of what I'm sending back to you.

In a weakly typed language, you can guess at what data structure I'm going to want. You can fish around in my returned data for what you're looking for with no guarantees. You have to look for docs, which may or may not be up to date.

But in a strongly typed language, the code is the doc. You and I and your IDE and my IDE are all on the same page. And the docs are always up to date. You can't pass me data that I'm not expecting and you always know how to access the data I'm returning to you.

Re:Angular 4.0.0 Now Available by azurelogic on Friday March 24, 2017 @10:12AM (#13948987)
Try Vue.js. It's what Angular 2 could have been, if they had taken proper advantage of ES2015 and virtual DOM. Another way of looking at it: Angular 1 and React had a baby, and they named it Vue.js.

Vue has HTML templates like Angular and virtual DOM like React. It is faster than both of them. It has a smaller file size than both of them. It has a clever single file component concept that makes developing components much easier. It uses a one-way data flow concept like React+Flux. Vue even has it's own competitor to redux/mobX called Vuex, and what makes it easier is that Vue is cognizant of Vuex's existence. There are really solid dev tools for Chrome as well (Vue and Vuex are aware of the dev tools as well).

I run a dev meetup, and I had planned to give a talk there on Angular 2. I even gave talks on JS tooling a year ago and TS last summer in preparation. Instead, I gave a talk on Vue this month, and people loved it. Here are the slides if you want to check it out (there are even embedded Vue apps!): https://azurelogic.github.io/vue-js-2.x-talk/#/

Re:Angular 4.0.0 Now Available by xj9 on Friday March 24, 2017 @11:49AM (#13949705)
i've built large applications in both Vue and Angular 2 and i still prefer Angular. don't get me wrong, Vue 2 is really nice, but i strongly prefer TypeScript over any JavaScript revision. Flow is helpful, and Vue 2 has typings, but it isn't quite as powerful as working with a TypeScript framework building a TypeScript app.

to each their own, of course.

Re:Angular 4.0.0 Now Available by azurelogic on Sunday March 26, 2017 @03:40PM (#13962723)
I'm on the fence about TS. I see the value in it, but it can be a lot of trouble to use, and I have found that the mistakes I make are almost all caught by a ESLint (and the remaining mistakes aren't type system mistakes).
Re:Angular 4.0.0 Now Available by jeppebemad on Friday March 24, 2017 @11:16AM (#13949438)
Coming from Angular 1, having tried and enjoyed React, Vue is godsend! I've been working with it for a few weeks and my productivity has skyrocketed. Debugging is amazing and their webpack templates just work. The learning curve with an angular background is almost flat, and the ecosystem is surprisingly mature already.

I don't care about templates being "bad" a as long as it works for us. I'm sold.

Re:Angular 4.0.0 Now Available by boredpudding on Friday March 24, 2017 @10:18AM (#13949021)
Thanks to this comment I'm looking at it now. The only thing I hate is 'v-for="todo in todos"' as an html attribute. I would personally prefer a mustache-like syntax.

Other than that, this looks awesome. Time to develop a todo app.

Re:Angular 4.0.0 Now Available by ng12 on Friday March 24, 2017 @10:48AM (#13949222)
Why are HTML templates a good thing? It's hands down my least favorite part of Vue.
Re:Angular 4.0.0 Now Available by VertigoJenny on Friday March 24, 2017 @11:03AM (#13949351)
It makes integration with existing code trivial. Vue's HTML templates can be neatly integrated into pretty much anything without a struggle compared to tools that make assumptions about your build chain and what you are working with. To use Vue, you could include it with a <script> tag and suddenly your existing HTML can be rapidly extended. Or you could get way more involved and use webpack, JSX and such if you wanted to.

To not have HTML templates means you need to do something more invasive to retrofit client-side templating into place. It's personally why I don't bother with libraries that don't offer similar, because I don't always have total control over what I am working on and I still need to get work done.

Re:Angular 4.0.0 Now Available by azurelogic on Sunday March 26, 2017 @03:36PM (#13962704)
I find them to be helpful in being able to see the markup as a complete chunk, without code getting in the way. In teams with "coders" and "designers", this also makes it easier for the designers to understand the components and do their work.
Re:Angular 4.0.0 Now Available by catenthusiast on Friday March 24, 2017 @10:58AM (#13949308)
You don't even have to know use them. You can use render functions or JSX like React.
Re:Angular 4.0.0 Now Available by equasar on Friday March 24, 2017 @11:32AM (#13949568)
I'm glad that Angular 2 is the way it is because it allows to build enterprise-sized applications more easily that using Vue.js.

I love Vue.js too, but just for small projects or when I need to add some complex functionality to an existing site that is not SPA.

I guess it comes down with the saying "the right tool for the job".

Re:Angular 4.0.0 Now Available by camus2 on Sunday March 26, 2017 @12:41AM (#13959192)
> I'm glad that Angular 2 is the way it is because it allows to build enterprise-sized applications more easily that using Vue.js.

That's just FUD, there is nothing in Angular that makes it more oriented toward Enterprise than Vue.js, unless you consider bloat an necessary component of any enterprise oriented solution, which is obviously a lie. What will decide which framework is "enterprise" is the ecosystem, the amount of widgets, not the bloat.

> I guess it comes down with the saying "the right tool for the job".

Exactly, the right tool for the job, AKA using a library that does only what it should do instead of trying to be anything and everything because its creators think the complex it looks, the more enterprisey it sounds. They will learn the hard way, and so will you.

Re:Angular 4.0.0 Now Available by zdragnar on Friday March 24, 2017 @10:03AM (#13948946)
I have built multi-10k+ line applications in angular 1, 2 and react. My personal preference is react by a mile.

The concept of modules and dependency injection was nice before we had any sort of module systems, but at this point it's essentially entirely busy work, given tools like proxyquire when testing.

Template compilation errors are a nice step up from 1, but those that I've seen have been very misleading and have been the cause of wasted hours debugging.

Angular 2 makes extensive use of the Reflection API for metadata, which combined with the fact that angular-cli is hard-coded to perform static analysis (even if you disable AOT) is another pain point. I'm trying to build the equivalent to "react storybook" for our platform, and it's taken me about 3x the time it would have with React.

With all of that said, if you need a "think-inside-the-box" tool for a large, decentralized dev team, angular can win out- there are fewer places to look for documentation, which will be nice when angulars documentation improves.

I actually find that React better encourages smaller, cleaner components with fewer responsibilities, but that's also likely due to being very familiar with the redux paradigm.

Finally, if you want very flexible components, react wins hands down, because components can be used as properties to other components; dynamically rendering components in angular has always had an inversion of control issue.

That's been my experience; ymmv.

Re:Angular 4.0.0 Now Available by danielpatrick on Friday March 24, 2017 @02:48PM (#13951217)
You've build multi 10k+ line applications in Angular 2?

It was released 5 months ago.

Re:Angular 4.0.0 Now Available by petar_prog on Saturday March 25, 2017 @07:23PM (#13958053)
With my team, we have developed using Angular 2.0 beta candidate mid-size banking application for one of the biggest swiss banks, plus complex hypothec management and transfer application which is public on the bank website. We pretty much managed to release the apps before actual Angular 2 official release, and then we upgraded apps to official versions. It was really interesting to experience and it all went really smooth but we had to use Redux (just a note). So yes, there are some of us who are doing production ready code before the actual frameworks are released. Bold move, but a smart one in our case. Apps are almost bug-free (really edge cases are minor bugs). I do have to note that we are all Full Stack Java devs who have experience in banking and complex applications for a long time, plus we focused a lot on Angular in the past, so this transition with Typescript and Angular 2 syntax was a charm for us.
Re:Angular 4.0.0 Now Available by zdragnar on Friday March 24, 2017 @03:02PM (#13951342)
One in angular 2, two in 1, and another that was a maaasive project in react. Team sizes varied from 3 devs to 12 or 16 (I forget which)
Re:Angular 4.0.0 Now Available by danielvf on Friday March 24, 2017 @02:58PM (#13951308)
Not GP, but it's been publicly available long before that.
Re:Angular 4.0.0 Now Available by daliwali on Friday March 24, 2017 @10:19AM (#13949026)
There is probably a non-trivial amount of astroturfing here, but also software developers are people too, and people get dogmatic about their opinions.

I probably won't ever use Angular unless I find myself desperate for work and can't find anything else. The problem I see inherent in frameworks is that they are all dogmatic about their opinions, and thus criticism of frameworks often do boil down to "I don't agree with their opinion", sometimes with rationalizations mixed in.

Preferences aside, Angular is objectively one of, if not the most, heaviest frameworks for web front-ends. It is not just a matter of bandwidth to the end user, but also a lot of magic under the hood that developers have to deal with. Consider the Java mindset that may have inspired Angular, people don't want to deal with that level of verbosity and enterprise mentality.

Unfortunately, there are increasingly few employment options if you want to use anything other than React or Angular. So rather than framing this argument in terms of framework hate, consider it a problem that lots of developers are forced to use these frameworks in order to be more like easily replaceable cogs in a machine, or be unemployed.

Re:Angular 4.0.0 Now Available by throwasehasdwi on Friday March 24, 2017 @10:43AM (#13949183)
given that both frameworks are open source I highly doubt any astroturfing on either side. I think what you're seeing is a bunch of developers riled up :)
Re:Angular 4.0.0 Now Available by daliwali on Friday March 24, 2017 @11:12AM (#13949409)
How ironic is that comment coming from a throwaway account... Given that both frameworks are products of multi-billion-dollar corporations, used mostly in commercial applications, and keep a fair number of people employed, I think it's a bit more than just getting riled up.
Re:Angular 4.0.0 Now Available by tomelders on Friday March 24, 2017 @12:32PM (#13950085)
I've got experience with Angular 1, 2, React+Redux, with teams of 5+

For me, the real problems in web app development are

1. State management

2. Side effects

3. View layer performance

Angular pales by comparison to things like React+Redux which were born out of necessity, and as such, tackle those issues with laser like focus.

Angular doesn't feel like it was born out of necessity, but out of some desire to just build a framework. As such, it's complicated and magical feels clumsy by comparison.

When combined with things like Immutable, Sagas, and ReSelect, the Redux/React style of architecture (feel free to swap out Redux or React for whatever you prefer) is so much more practical and useful compared to Angular.

I don't know what it is that makes Angular popular with back end developers, but they seem to be Angular's biggest supporters. I consider my self full stack, but front end first, and I've noticed that people like me tend to favour libraries over frameworks. There's obviously something that is informing each groups opinions on this matter, but I don't know what it is.

Re:Angular 4.0.0 Now Available by kevindqc on Friday March 24, 2017 @12:41PM (#13950169)
>When combined with things like Immutable, Sagas, and ReSelect, the Redux/React style of architecture (feel free to swap out Redux or React for whatever you prefer) is so much more practical and useful compared to Angular.

You can use all that with angular 2. I am.

Redux -> @ngrx/store

Immutable -> same

Sagas -> @ngrx/effects

ReSelect -> same

Example here: https://github.com/ngrx/example-app

Re:Angular 4.0.0 Now Available by tomelders on Friday March 24, 2017 @12:58PM (#13950337)
But why? If you're adding all of that to make Angular work the way you want it, what benefits are you actually getting from Angular?
Re:Angular 4.0.0 Now Available by kapv89 on Friday March 24, 2017 @01:42PM (#13950709)
Same question can be asked for react. FYI you can easily build decent sized apps in react without redux
Re:Angular 4.0.0 Now Available by tomelders on Friday March 24, 2017 @03:19PM (#13951480)
Exactly. Thats my point.
Re:Angular 4.0.0 Now Available by shadowmint on Friday March 24, 2017 @10:47AM (#13949213)
I can only speak from personal experience, but I've worked on 2 SPA angular apps that were both a nightmare.

The react apps I've worked on have been much more successful; we haven't had to throw the whole thing away (unlike one of those angular ones...)

I'm sure other people have had other experiences, but after two terrible experiences, the questions I would ask are:

- Why would I bother looking at angular again?

- What has significantly changed in the last year to reduce the complexity, increase the component ecosystem or increase the quality and quantity of the documentation?

If you can't answer either of those with meaningful answers, I don't see any reason, given the other alternatives to angular that are around, to try using it again.

Re:Angular 4.0.0 Now Available by hamstercat on Friday March 24, 2017 @08:52AM (#13948538)
I started with Angular 1 and like it very much. Like you said, it enabled me to structure the code a certain way that made understanding it easier. I tried Aurelia since and moved on to React, and I have to say that while I still like Angular, not having to deal with state and mutability everywhere is a big boon to productivity. Whenever I code a component, I can simply think of the props (it's parameters) and the output (the HTML).

That being said, Angular is still a valid option (haven't tried Angular 2, but from what I've read it's a nice upgrade over Angular 1). I'd still take React any day of the week over it, just for the simplicity it brings. Of course there are other drawbacks to using it, but nothing's perfect.

Re:Angular 4.0.0 Now Available by ddito on Friday March 24, 2017 @10:56AM (#13949292)
I would suggest trying ng2 before dismissing it over experiences with ng1. I was having huge issues with ng1 with updating scope and simillar things and then I tried ng2 first for a hobby project then a bigger collab one and if theres one thing I can say it's that Google did serious damage to the project by reusing the branding for two different frameworks for both searching/googling purpouses and by reusing branding from a framework which isn't similar and has been dismissed by many already. I hear too often how people say react is better than angular without trying ng2. It's like saying python is better than c# 1.0. Maybe it is but youre not making a fair comparison
Re:Angular 4.0.0 Now Available by hashkb on Friday March 24, 2017 @08:55AM (#13948556)
What else have you used? Having spent time in both Angular and React, I can say from experience I'm more productive and less angry while working in React. Less to learn, much simpler, yet no less powerful.
Re:Angular 4.0.0 Now Available by stephenhuey on Friday March 24, 2017 @09:30AM (#13948758)
I started using Aurelia for one of our projects back in January 2016 and I find it both straightforward and powerful. I've been building web apps for 14 years and Aurelia is big on following web standards. I had used Angular for a project back in 2012 and found it very Java-esque and not so intuitive. The founder of Aurelia left the Angular 2 team because he felt they weren't choosing to follow standards. Aurelia's community is growing and has an active Gitter channel, so drop by and check it out!
Re:Angular 4.0.0 Now Available by boubiyeah on Saturday March 25, 2017 @08:15AM (#13955245)
Angular is a huge framework with a very OO style written by java devs. You have to learn many things to be productive with it, including a really weird string templating language.

The most funny thing probably is the typescript sale pitch (I use and like typescript) where you actually don't beneficiate from typescript at all with half of angular (string templates means no type checking or intelliSense on component names, model properties, component apis, etc)

It's also pretty fat and not exactly performant. It's simply a no-no on mobile. Its niche use case seems to be backend developers who know OO well, FP not so much, developing low/average quality back-office apps quickly without having to care about what's going on behind the scene.

The angular core devs always favor magic and shortcuts over simplicity. Its API surface is enormous, so have fun keeping up with the versions. It's optimized to get started quickly and be decently productive as long as you only use the core directives.

It's not terrible, but it's just not good if you care about the UX and maintainability of your app.

Re:Angular 4.0.0 Now Available by lenkite on Saturday March 25, 2017 @01:09PM (#13956560)
The ionic developers are using angular 2. http://ionicframework.com/docs/v2/intro/installation/ . So it it isn't a 'no-no' on mobile as you put it. Angular 2 AOT produces very lean JS.
Re:Angular 4.0.0 Now Available by Touche on Friday March 24, 2017 @11:28AM (#13949543)
I still need a good reason why I need DI built into a framework and the following is not sufficient:

  SomeClass.SomeDep = MockDep;
In other words, inject through static properties. I do this with normal classes to test models and the like with no issues. No DI container necessary.
Re:Angular 4.0.0 Now Available by smdz on Friday March 24, 2017 @03:14PM (#13951446)
Angular 1 was great. It was first of its kind. And it was just a bit complex - but not too much.

Ng2 felt too different. Ng1 to Ng2 made me look outside and there was React gaining ground - perfect timing. In its original state React is so much simpler than Angular. But then React with just the basics can make you create bad code - that's what happened to me. React with best practices - is hard to digest.

So I went back to Ng2 - soon enough I was craving to go back to React. Suddenly I started hating Angular2 (but loved TypeScript).

I spent time learning React best practices - that require some patience. But one thing I brought on from Ng2 was TypeScript. TS makes you a lot more productive. Now React and TS is not a widely accepted combination - but its very productive as your app grows.

Re:Angular 4.0.0 Now Available by andrei_says_ on Friday March 24, 2017 @01:35PM (#13950654)
Please take a look at Vue.js. I'm being redundant, intentionally.

There's something about it -- feels clean and minimal, works really well with my ruby- and rails- influenced mind, organizes my thinking about an app and makes it easy to have things in their right places, at a correct level of abstraction, effortlessly.

My reaction after encountering vuejs was one of relief -- finally seeing an option I resonate with, a vision driven by someone whose thinking is aligned with my desire to avoid confusion, complexity and frustration.

The free screencasts at laracasts and egghead.io are quick and fantastic.

https://laracasts.com/series/learn-vue-2-step-by-step

Re:Angular 4.0.0 Now Available by nck4222 on Friday March 24, 2017 @10:02AM (#13948939)
I loved working with angular. They lost us when they released angular 2. It was complete breaking changes and the upgrade path was a nightmare. They basically were forcing users to completely rewrite their front-end if they wanted to upgrade. So the team figured if we have to rewrite our front-end, what's keeping us on angular and why would we stick with a framework that doesn't seem to have any issues forcing it's users to do complete rewrites just to use the newest version?
Re:Angular 4.0.0 Now Available by Syntaf on Friday March 24, 2017 @11:16PM (#13953928)
I wrote https://www.smsforecast.com using Angular2 and personally love the changes made from 1.X, I'm happy to see 4.0 come out along with it's bug fixes and features.

1.X felt messy, but writing web apps in Angular > 2 feels really clean when done right.

Re:Angular 4.0.0 Now Available by mstijak on Friday March 24, 2017 @11:14AM (#13949417)
I would recommend CxJS as an alternative. It has the best mix of Angular and React features such as JSX based view, two-way data-binding, controllers. On top of that, a large collection of widgets and charts is included out of the box and we're soon to release a Material Design based theme.

https://cxjs.io/examples

Disclaimer: It's a commercial product and I'm the lead developer.