@juan-carlosJuan Carlos Yovera Cruz
Senior Front End, UX/UI specialist with more than 14 years’ experience in development of software
When you need to create a Single Page Application, your first idea should be to search for the best framework to implement it. We have a lot of frameworks but 3 are very famous: Angular, React, and Vue.js. Today I will teach you about Angular, its advantages, disadvantages, and how you can start to learn it.
Why not? Angular is an open-source platform developed in 2009, it has made huge updates and improved features to make it lighter and faster. It is one of the most popular software development instruments and now Angular has a big community which increases every year. Of course, we can mention some advantages and disadvantages to this framework.
” The platform-agnostic philosophy “
Cross Platform: You can use modern web platform capabilities to deliver app-like experiences, for example, Progressive WebApps, Build native mobile apps with Ionic or NativeSCript, and also you can create desktop apps across Mac, Windows, and Linux.
Productivity: Angular isn’t just a framework, it is a Platform. For this reason, it has good tools to increase your productivity in development cycles. For example, you can create UI with simple and powerful template syntax. Also you have Angular CLI, where you can start building fast and add components, services, test, then instantly deploy. I think we can mention TypeScript, this language is awesome and the best way to learn angular very fast.
Component-based architecture: It provides a higher quality of code. It is one the things that improves architecture and is used by almost all JS frameworks with some benefits. For example, reusability, readability, unit test friendly, and maintainability.
Google and Microsoft are good sponsors: Some software engineers consider the fact that Angular is supported by Google as a major advantage. Also, Microsoft helps with Typescript and now Angular is written in this language.
Functionality out of the box: You won’t need to use any third-party libraries to create basic functionality for your app. All you need is the Angular CLI, which is provided by the Angular team. This means that you can expect better security and higher code quality.
Bundle Sizes (Ivy): Ivy is the new engine template in angular, it can enable smaller bundles because it uses the Ivy instruction Set which is a set of tree-shakable runtime rendering instructions. Our bundles will only include the rendering instructions we use in our projects.
This is great for use cases such as micro frontends, Angular Elements, and web apps where Angular is not controlling the entire document.
Well, until now everything looks perfect, but let’s examine the main drawbacks of Angular.
Learning curve: It’s easy to learn Angular in the basic stages. The moment you move towards the advanced stages, the learning curve turns out to be very steep. It will be challenging compared to React or Vue onboarding. The array of topics and aspects to be covered is large and some unique features of Angular are quite complex, so developers find it difficult to start working with it.
Limited SEO options: The big problem with SPA is search engine indexing. Engines still need to see the content and elements of the page in the source to guarantee that it will be indexed correctly. Angular has a tool “Angular Universal” to fix this problem, but it has a long road to cover to improve accessibility for search engine crawlers.
Angular versions: Angular has a lot of versions since version 2. It’s generating 2 releases per year, so if you are using the last version of Angular probably at the end of the year you’ll need to update again and sometimes this is a headache for DevOps teams.
When Should I Use Angular?
As I explained, there are many benefits of Angular: the use of Typescript to increase the maintainability of code, the improved performance, the architecture for Angular projects, and more.
As you make more complex applications and ecosystems for long-term and heavy investment projects, the steep learning curve is is worth the trade-off for increased stability and ongoing tech support.
The difference between Angular, react or vue.js could be that react and vue.js are easy to deploy and start working with, but they are definitely less flexible and harder to maintain than Angular. I think you should analyze what framework fits your project. Angular is not the solution for all; it depends on your business, experience, and your team.
However, if you are interested, here are some books to help you learn more about Angular:
- You Don’t Know JS Yet (book series) – 2nd Edition.- Looking for free material to learn JS we can’t deny the opportunity to read this resource which contains the most tricky stuff about JS (What does “this” mean? etc).
- TypeScript 2 For Angular Developers.- This eBook will help you to understand Typescript and combine it with Angular, an easy way to start learning angular.
- TypeScript 2.X By Example: Build engaging applications with TypeScript, Angular, and NativeScript on the Azure platform.- Explains in deep TypeScript then it’s combined with Angular and Nativescript which is the mobile alternative for Angular.
- Become Ninja With Angular.- I recommend this eBook which covers common parts of Angular with a good explanation of them.
Previously published at https://www.jucayovera.com/blog/article/9