Angular is a web framework invented by Google, it’s been so long and angular is evolving day by day, more functionalities are added, enhanced performance and suitable for higher interactivity website, due to this more and more organizations has started adopting angular as their product’s front-end. Angular is being popular amongst other frameworks and libraries, this many big and small companies are demanding Angular as a primary skill along with other backend support which turns its importance on a higher level into the industry. Due to such reasons, many developers are eager to learn this framework so that they can get benefits from their career perspectives. But they may have one question in their mind that Angular is interesting to learn but how can we leaned and how much time it will take? I would say, there is no direct answer to that because the experience of the candidate matters a lot and it may be.
- Beginner
- Intermediate
- Expert
So if we follow these experience level, the person should know JavaScript which is must for learning Angular, not just only Angular but there are tons of other frameworks and libraries are built on JavaScript so at last, we can say if you know the basic of JavaScript then you can start learning Angular right away.
1. Modular Angular Architecture
In theory, you can put all your Angular code on one page and into one massive function, but it’s not recommended, nor is it an efficient way to structure your code and defeats the purpose of Angular’s existence.
Angular uses the concept of modules heavily as part of the framework’s architecture. This is in reference to the collection of code that has a single reason for existing. Your Angular app is essentially made up of modules — some stand alone and some shared.
There are multiple ways to structure your modules within your application and digging into the different architectural structures can also help determine how you’ll scale your app as it grows. It can also help isolate your code and prevent code coupling from occurring.
What to Google:
- Angular architecture patterns
- Scalable angular application architecture
My take on the topic:
- What does Modular Architecture in Angular
2. One-way Dataflow and Immutability
Way back in Angular 1, two-way binding captured the hearts of many front-end developers. It was essentially one of Angular’s original selling point. However, over time it started to pose problems in terms of performance when the application started to become more complex.
It turns out you don’t actually need two-way binding everywhere.
Two-way binding is still possible in Angular 2+, but only when it is explicitly requested by the developer — thus forcing the person behind the code to think about the direction and flow of their data. It also allows the application to become more flexible with data by determining how data should flow.
What to Google:
- Angular data flow best practices,
- Uni-directional flow in Angular,
- Advantages of one way binding
My take on the topic:
The Tale of Unidirectional Dataflow in Angular
3. Attribute and Structural Directives
A directive is an extension of HTML through custom elements. Attribute directives let you alter the properties of an element. Structural directives change the layout by adding or removing elements from the DOM.
For example, ngSwitch and ngIf are structural directives because it evaluates the parameters and determines if parts of the DOM should exist or not.
Attribute directives are custom behaviors attached to the element, component or other directives.
Learning how to use these two directives can extend your app’s capabilities and reduce the amount of duplicate code in your project. Attribute directives can also help with centralizing certain behaviors that are used across different parts of the app.
What to Google:
- Angular attribute directives,
- Angular structural directives
- Angular structural directive patterns
My take on the topic:
The Low Down on Attribute and Structural Directives in Angular
4. Component Life Cycle Hooks
Every piece of software has its own life cycle that determines how something is created, renders and then removed. Angular has a component life-cycle that goes something like this:
We have the ability to hook into key moments within this cycle and target it at specific moments in time or event. This allows us to create appropriate responses and configure behaviors according to the different phases of the component’s existence.
For example, you may need to load some data before the page gets rendered. You can do this through ngOnInit() . Or perhaps you need to disconnect from a database. This can be done through ngOnDestroy().
What to Google:
- Angular life cycle hooks
- Component life cycle
5. Http and Observable Services
This isn’t really an Angular specific feature but rather something from ES7. Angular just happened to implement it as part of the framework’s support capabilities and understand this also translates well to React, Vue and any JavaScript related library or framework.
Observable services are patterns that allow you to effectively deal with data — allowing you to parse, modify and maintain data in an event-based system. You can’t really escape Http and Observables because everything is data.
What to Google:
- JavaScript observable patterns
- Angular HTTP and observables
- ES7 observable feature
6. Smart/Dumb Component Architecture
When writing our Angular apps, we tend to put everything into the component. However, that’s not exactly the best practice. The idea of smart/dumb components in Angular is something that needs to be talked about more, especially in beginner circles.
Whether a component is smart/dumb determines its role in the grand scheme of the application. Dumb components are often stateless with behaviors that are easy to predict and understand. Make your component dumb whenever possible.
Smart components are harder to grasp because inputs and outputs are involved. To properly leverage Angular’s capabilities, look into smart/dumb component architecture. It will give you patterns and mindsets on how to approach your code and its relationships with each other.
What to Google:
- Smart/dumb Angular components
- Stateless dumb components
- Presentational components
- Smart components in Angular
7. Application Structure and Best Practices
The CLI can only take you so far when it comes to structure and best practices. Building an Angular app (or any application in general) is like building a house. There are set processes that are optimized by the community over the years that will result in the most effective and efficient application.
Angular is no exception.
Most complaints towards Angular by those trying to learn it is often due to lack of structural knowledge; the syntax is easy to pick up and it is definite and clear cut. Application structural knowledge, however, requires an understanding of context, requirements and how it all fits together on a conceptual and practical level. Learning the different potential application structures for Angular and their best practices will give you perspective on how to build your application.
What to Google:
- Single repo Angular apps
- Angular libraries, Angular packages
- Angular bundles
- Angular micro apps
8. Template Binding Syntax
Binding is the icing on the JavaScript framework. It is also one of the reasons for existing in the first place. Template binding bridges the space between static HTML and JavaScript. Angular’s template binding syntax acts as the facilitator between these two technologies.
Once you’ve learned how and when to use them, turning a once static page into something interactive becomes much easier and less annoying. Look into the different scenarios for binding such as property binding, events, interpolation, and two-way binding.
What to Google:
- Angular property binding
- Angular event binding
- Angular two-way binding, Angular interpolation
- Angular passing constants
Responsibilities
- Delivering a complete front end application
- Ensuring high performance on mobile and desktop
- Writing tested, idiomatic, and documented JavaScript, HTML and CSS
- Coordinating the workflow between the graphic designer, the HTML coder, and yourself
- Cooperating with the back-end developer in the process of building the RESTful API
- Communicating with external web services