r/webdev • • Nov 04 '21

Angular v13 is now Available

https://blog.angular.io/angular-v13-is-now-available-cce66f7bc296
76 Upvotes

60 comments sorted by

16

u/[deleted] Nov 05 '21

Didn’t realize this sub had such a strong hatred for Angular.

12

u/axelwyr Nov 05 '21

Developers hate angular but don't know difference and pros/cons between AngularJS/angular/react/vuejs... What a world we work. If technical people don't know about technical stuff, why do they want HR and business people to understand it

-3

u/matrinox Nov 05 '21

Front end is much more likely to go homogeneous due to there often being only one app for the web. So even if Angular is much better in a specific scenario, it’s easier to just use the tool you use all the time and it’s also easier for companies to hire the larger pool

45

u/DeveloperOldLady Nov 04 '21

PEOPLE: angular 1 is not the same thing as angular 2. Angular 2 is compatible and written in the same way as angular 2-13. If you know angular 2 you know angular 13. There are breaking changes which are minor but can be learned. Angular is a great framework for scalable applications. Updating from v11 to 12 took about 30 mins. Each of these changes brings great improvements. Yall need to calm down with the hate.

5

u/shellwe Nov 05 '21

They absolutely should have called it something else. When I was trying to learn angular 4 or so there was so much content that was for angular and I was confused as hell trying to figure out what they did.

They should have kept angular 1 as angularJS and angular 2 as angularTS.

-1

u/[deleted] Nov 05 '21 edited Nov 05 '21

Angular 1 was actually useful. Angular 2 became tedious.

Has anyone built upon or updated angular 1? Perhaps under a different name? Because it's so damn useful for prototyping. I still use it in some older apps.

Principles and separation of concerns is fine when you're 18 and think the world is pure and ideological and you can spend a month on 50 different projects that never go anywhere.

Then you grow up and want to get shit done. Today. I don't want to have to learn a new fucking paradigm to make a quick single page prettifier of some third party json data.

12

u/sadpremonition Nov 04 '21

someone tell Ben Awad

0

u/joel-44 Nov 04 '21

After the drastic change from angular 1 to angular 2 I totally abandoned it in favour of vue.js, I never had any regret about it.. seeing how fast the versions in angular advances, anyone can tell me any advantage of angular over vue.js nowadays? Thank you!

26

u/the_letter_y Nov 04 '21

I used Angular at my previous job, and am now using Vue. Honestly, I wish I could go back to Angular. I will preface that by saying it's very much context-dependent - Vue definitely has less of a learning curve and is much simpler to set up, so it lends itself better for smaller projects/teams. But if you're working on a complex, highly interactive web application with a lot of state, and have a diverse team of developers with varying experience levels, Angular is so much better.

Having worked with both, here are my observations:

  • With Vue, you typically have to maintain your own bundler config, and there is less standardization, so every project is different. Getting proper sourcemaps, or being able to embed SVGs, load fonts, etc., can quickly get out of hand. Our webpack config is more than 500 lines of code now, and few people are brave enough to touch it. I'm not sure if Vue 3 or other bundlers like Vite has made that any easier (we're still on Vue 2 + webpack). But with Angular, we never had to mess with it, it just provided everything a complex web application would need out of the box, and it worked exactly like you would expect.

  • This may again be a criticism of our webpack configuration more so than Vue itself, but the generated sourcemaps are pretty awful, which makes debugging a nightmare. Like you put a breakpoint and then "step over", and it takes you somewhere else completely (and it's clearly wrong). I've resorted to using console.log and debugger statements. I've been told the team has experimented with different sourcemap strategies, and while the end result is not great, it was the best tradeoff in terms of compile times. With Angular, while it also wasn't perfect, it was never this bad, and again there was zero configuration we had to do, it just (mostly) worked.

  • Angular definitely lends itself much better to complex web applications with diverse teams, particularly because of its native TypeScript support. I know a lot of people are opposed to TypeScript for some reason, including on my current team, but the added compile-time safety, better Intellisense, and better doc comments are all huge wins in my book. With the Vue codebase I'm currently working in, every object is like a mystery object, I have to put a breakpoint or console.log it to see what properties it has. It's time consuming and error-prone. And while you can use TypeScript with Vue, it seems you don't really get the full benefit, since there are things you can't type annotate, and in general the TypeScript support has many limitations.

  • This may be opinion based, but I really prefer the Angular way of organizing component files. With Vue, we use Single File Components (SFCs), which in my opinion makes it hard to navigate. Like is there a quick way to jump to the script section or the styles section of a file (using WebStorm)? I tried a plugin for this, and it didn't work. I need to do a bit more research on this, but for now I've been doing what I think everybody else has been doing, which is just a lot scrolling. With Angular, the "template" (html), styles, and "script" (controller), and tests were separate files grouped within a folder, which I thought was a lot easier to navigate.

  • I also feel like the Angular conventions scale much better as the project grows, whereas Vue doesn't really impose or even suggest a structure, so everyone just kind of ends up doing their own thing (or sometimes it just ends up becoming a big mess).

  • Testing support seems pretty awful. Angular provides so much more tooling and guidance on how to test components for every scenario, and provides mock objects for everything (HTTP client, router, etc.). With Vue, it seems my team has given up on automated testing years ago (way before I even joined) because it's just too hard. Like there's no formal concept of "services", you just export functions from a module - but then you can't mock or stub those functions without using something like the webpack rewire plugin (or similar), but many of those either break something else, or are no longer supported, etc. With Angular, testing was more of a first class citizen.

So yeah, those are my 2 cents. Again, some of those criticisms may be more of how our team does things, or maybe our webpack config rather than Vue itself. But then again, because Angular provides all these things out of the box, and the setup works well for nearly every use case you can think of, so you never even have to directly mess with bundlers at all (whereas that doesn't seem to be true of Vue or even React), maybe it is a criticism of the framework somewhat.

3

u/pyronautical Nov 05 '21

At a previous company I was working as a practice lead across an engineering of 40ish in the software services space. So new projects being spun up all the time. And I had to pick between all new projects being Vue, React or Angular.

And your post is exactly why I went with Angular in the end. It just scales very well and scales the exact same way every single project. We still used React on various projects but every time the tech lead would go “well I like this library so I’m going to do it this way” whereas angular says “here’s the out of the box way so… probably just use that”. There is very few, If any angular projects that developers can’t just move between and be instantly up to speed.

1

u/[deleted] Nov 05 '21

That’s exactly why I hate using angular. The out of the box way feels like a bunch of .net devs who don’t grok modern paradigms put a framework together.

If you want consistency outside of angular, take a look at a comparable framework like next.js

Comparing angular to react is of course unfair. Angular is a heavily opinionated batteries included framework. React is a view rendering library.

2

u/light24bulbs Nov 04 '21

Actually, the bundler config with vue is all built into the vue-cli and it's probably the best bundler setup, period. You never have to eject the config like with other tools, there are a series of hooks and you can extend whatever part you need while still keeping the core of the bundler controlled by the vue cli. It's really, really good

16

u/Knochenmark Nov 04 '21
  • Angular just scales way more gracefully

  • more flexible in regards of state-management

  • way better typescript support

  • great support for async/observables

  • best forms-module

  • more standardized/opinionated works better for larger teams

just to mention a few

4

u/Dangerous-Bed-5335 Nov 04 '21

I’m over here tryin’uh figure out what jQuery can’t do

15

u/joel-44 Nov 04 '21

we can also try to figure out what javascript can't do but jQuery does...

1

u/Dangerous-Bed-5335 Nov 05 '21

You obviously know that jQuery can’t “do” anything javascript can’t, but it does enable developers to write much less code than they would if they wanted the same results writing pure JS. So it saves time in development, and money.

1

u/joel-44 Nov 05 '21

You obviously know that Vue/Angular can’t “do” anything jQuery can’t, but it does enable developers to write much less code than they would if they wanted the same results writing jQuery. So it saves time in development, and money.

1

u/Dangerous-Bed-5335 Nov 07 '21

jQuery did it first.

jQuery is Dr. Pepper, Angular is Mr. Pibb, Vue is Pibb Xtra, and React is Dr. Thunder. Dr Pepper is the only real Doctor, the Pibb’s were copy cats and didn’t even get a PhD, and Dr. Thunder is a cut rate chiropractor with a cult like following that will eventually poison everyone that trusted him

4

u/azangru Nov 04 '21

I'm wondering what's the point of pulling 30kB of jQuery these days anyway. The time when browsers had clumsy inconsistent apis is long gone.

2

u/mrpink57 Nov 04 '21

Sitecore enters chat ...

1

u/Dangerous-Bed-5335 Nov 05 '21

Pulling 30kb (.03MB) is trivial when talking in the context of the average website.

1

u/azangru Nov 05 '21

Compare it to Preact's 4kb, or Svelte's 1.6kb, or Lit's 6kb; and the question becomes, what's the value that jQuery brings to the table with its 30kb. Just a dot-chaining api?

1

u/TrollocHunter Nov 04 '21

My main reason to abandon Angular for Vuejs is because Vuejs is leaner, simpler, and faster to prototype POCs.

28

u/[deleted] Nov 04 '21

[removed] — view removed comment

1

u/joel-44 Nov 04 '21

glad not all the changes are like the first one :D
I think we all look for simplicity when using a framework and all the confusion and mess it caused the first upgrade scared us away forever, if they would have handled it in a more empathic maner to the current users the scenario would be pretty different at the moment

0

u/tauqr_ahmd Nov 05 '21

Great! Now waiting for recruiters to include angular 13 in job requirements.

0

u/[deleted] Nov 05 '21

[deleted]

1

u/tauqr_ahmd Nov 05 '21

all my projects still at angular 7 and 8..and some on 6 too.. they might drop a ugh in disgust at the end of call.

0

u/[deleted] Nov 05 '21

I switched from Angular to React years ago and haven’t looked back since.

-12

u/WhatBoizz Nov 04 '21

Someone make it stop D:

-44

u/letsgetrandy 25 years putting the magic in the box Nov 04 '21

When I was looking into learning Angular a little over a year ago, it was on v8. Today we're now on v13. Most actual job descriptions I see that mentioning Angular are still using v3. This is why I have never bothered to become an Angular developer.

49

u/Potato997 Nov 04 '21

Cool stuff taking in consideration that Angular v3 doesn't exist

11

u/Obese-Pirate Nov 04 '21

Yeah, they might be thinking of v2, which is what recruiters/hr use as a generic catch all for "not Angular JS"

6

u/15kol Nov 04 '21

Apart from change where they raised major rxjs version, there was hardly any work to be done when upgrading (and I use Angular since v4). You obviously don't use Angular, neither did you had to upgrade its major version.

2

u/Knochenmark Nov 04 '21

Man I remember the Rxjs update, they changed everything to pipeables! Updated 2 larger codebases back then.

4

u/Obese-Pirate Nov 04 '21 edited Nov 04 '21

I believe Angular releases major versions on a quarterly schedule now every 6 months now (I was mistaken). It hasn't always been this way, but I really do enjoy it as they seem to be adding very nice improvements at a solid pace.

2

u/magenta_placenta Nov 04 '21

I believe Angular releases major versions on a quarterly schedule now.

Documentation is still stating every 6 months which it's been for a long time now:

"In general, expect the following release cycle:

A major release every 6 months"

1

u/Obese-Pirate Nov 04 '21

Oops, guess I was mistaken, sorry.

4

u/letsgetrandy 25 years putting the magic in the box Nov 04 '21

Major version releases mean breaking changes.

Full stop.

If you're breaking backward compatibility 4 times a year, your software is the wrong choice for my company's architecture.

3

u/redfournine Nov 04 '21

Tbh I dont understand why it's a major releases when there is minor changes (at least not as major as what it is perceived to be) between major versions. I think after v8 or v9, the upgrade was very uneventful...

2

u/Knochenmark Nov 04 '21

its a major version everytime because of the ts-compiler version

5

u/Obese-Pirate Nov 04 '21

They make it pretty easy to migrate with a solid migration system. It's really not bad and in my opinion it's worth it. Totally cool if it doesn't with for you though. That's why there's multiple frameworks I suppose.

-4

u/svtguy88 Nov 04 '21 edited Nov 04 '21

solid migration system

So, you'd advocte for taking on a front-end framework upgrade (with breaking changes) every quarter? Yeah, that shit just isn't going to fly in a real company with budgets, and other projects that aren't "upgrade existing functionality."

Angular has its place. That place just isn't with any clients I work with.

7

u/Obese-Pirate Nov 04 '21

It's a single command you run and it fixes everything that needs to be fixed for you. It takes minutes and it's easy. I'd rather have that than be stuck in the past for sure.

-1

u/svtguy88 Nov 04 '21

That's assuming your entire app is covered by automated testing. I've worked with a lot of clients over the years, and I have yet to meet an app that I would put the label "100% coverage" on. Most places don't even have proper backend testing, let alone the frontend.

If you don't have testing, you basically have to regression test the whole thing, and that takes time, which translates to a loss of capacity for other projects.

3

u/Obese-Pirate Nov 04 '21

You also don't have to upgrade the framework, which appears to be what you're most comfortable with.

Just stick to whatever version you're able to, it works the same as whatever you're currently doing that doesn't update twice a year.

I'd recommend at least basic front end tests for any environment though. Do you just not upgrade whatever framework you're working with?

-9

u/letsgetrandy 25 years putting the magic in the box Nov 04 '21

You have to consider the amount of time that has to go into using the migration system, as well as the time spent reading over changelogs, and the time spent on regression testing your app, and the risk of any other dependencies being incompatible with the change... all of this shit takes up time that could be spent on developing new features that actually serve your business, rather than maintaining a framework that keeps Google employees happy.

Again... this is why every company out there that actually uses Angular is still on v3. They've decided to spend their time on shit that makes them money.

6

u/Obese-Pirate Nov 04 '21

Considering I use angular in a full time capacity, I do consider those things. It works for me and it's really not as bad as you're playing it up to be.

Also, if you don't already have testing in place and you're not interested in it, I guess that's on you. I don't do it as much as I should, but I'd still highly recommend you have tests written for your code. Really helps with upgrading any framework, not just Angular.

0

u/[deleted] Nov 04 '21

[deleted]

9

u/Obese-Pirate Nov 04 '21

Hey, I'm a developer that works full time with Angular. Nice to meet you.

6

u/ADuckInReddit Nov 04 '21

Hey, I'm a developer that works full time with Angular too. Nice to meet you all

-9

u/Wilesch Nov 05 '21

So glad I decided to take the react path. How different my life would have been.

5

u/Brisklemonade123 Nov 05 '21

React overrated

-21

u/Farghaly Nov 04 '21

I don’t care since angular was 1

3

u/IonelLupu Nov 05 '21

V1 is different than v2 and the rest. So you are comparing the wrong tools

-17

u/light24bulbs Nov 04 '21

booooo hissss

0

u/[deleted] Nov 04 '21

[deleted]

3

u/Sandurz Nov 05 '21

Performance boost was huge as were the tooling improvements but the compiler and dev server got wayyyy slower.

0

u/[deleted] Nov 04 '21

[deleted]

11

u/Aewass Nov 04 '21

A lot of people, including like several companies across Europe that I've worked with.

Idk about you, but a large number of enterprises are working with Angular because it's perfect for large, complex projects.

0

u/[deleted] Nov 04 '21

[deleted]

11

u/Aewass Nov 04 '21

And? That doesn't change the fact that Angular is a good solution for some cases and React for others.

0

u/[deleted] Nov 04 '21

[deleted]

10

u/Aewass Nov 04 '21

I mean, stay salty as much as you want, but that doesn't change the fact that companies use Angular and will continue using it.

I'm learning other frameworks too and can appreciate all of them for what they are worth.

4

u/rubennaatje Nov 04 '21

I'm more of a react fan but I think you don't get it tbh.