Sign In Start Free Trial
Account

Add to playlist

Create a Playlist

Modal Close icon
You need to login to use this feature.
  • Switching to Angular
  • Toc
  • feedback
Switching to Angular

Switching to Angular

By : Minko Gechev
3 (5)
close
Switching to Angular

Switching to Angular

3 (5)
By: Minko Gechev

Overview of this book

Align your work to stable APIs of Angular, version 5 and beyond, with Angular expert Minko Gechev. Angular is the modern Google framework for you to build high-performance, SEO-friendly, and robust web applications. Switching to Angular, Third Edition, shows you how you can align your current and future development with Google's long-term vision for Angular. Gechev shares his expert knowledge and community involvement to give you the clarity you need to confidently switch to Angular and stable APIs. Minko Gechev helps you get to grips with Angular with an overview of the framework, and understand the long-term building blocks of Google's web framework. Gechev then gives you the lowdown on TypeScript with a crash course, so you can take advantage of Angular in its native, statically typed environment. You'll next move on to see how to use Angular dependency injection, plus how Angular router and forms, and Angular pipes, are designed to work for your projects today and in the future. You'll be aligned with the vision and techniques of the one Angular, and be ready to start building quick and efficient Angular applications. You'll know how to take advantage of the latest Angular features and the core, stable APIs you can depend on. You'll be ready to confidently plan your future with the Angular framework.
Table of Contents (10 chapters)
close

What this book covers

Chapter 1, Switching to the One Angular, makes an introduction of what Angular is. You'll learn that Angular and AngularJS are entirely different frameworks. After that, we'll go through the basics of the structure of the framework—having a core with a minimalistic and immutable API, and building on top of it with different modules in order to provide the best development experience possible. Finally, we'll see how Angular follows semantic versioning, which helps us understand why and when we should expect incompatible API changes in Angular.

Chapter 2, Get Going with Angular, teaches why we should use the latest version of the JavaScript language, why to take advantage of web workers, and how Angular takes advantage of all these powerful technologies. We will observe the current direction of frontend development and the lessons learned in the past few years. The chapter describes why AngularJS's architecture was changed in order to allow the development of SEO-friendly, high-performance, single-page applications.

Chapter 3, The Building Blocks of an Angular Application, gives a quick overview of the main building blocks provided by Angular for the development of SPAs. We'll point out the main differences with the core concepts from AngularJS.

Chapter 4, TypeScript Crash Course, introduces you to the TypeScript language that is used for the implementation of Angular. While exploring the language, we'll look at some of the core features of ES2015 and ES2016. We will explain the ES2015 and ES2016 classes, arrow functions, block scope variable definitions, destructuring, and modules. Since Angular takes advantage of the ES2016 decorators, and more accurately their extension in TypeScript, a section here speaks about them. After this, we'll take a look at how we can take advantage of static typing using explicit type definitions. We'll describe some of the built-in types in TypeScript and how we can define classes in the language by specifying access modifiers for their members. In the end, we'll explain what structural typing is and how TypeScript's type system takes advantage of it.

Chapter 5, Getting Started with Angular Components and Directives, takes us through the core building blocks of an Angular application: directives and components. We'll build a couple of sample components to show us the syntax to be used for the definition of these fundamental building blocks. You'll learn about the life cycle of each directive and the core set of features the given directive and component have. In the next step, we'll see how we can enhance the performance of our application using Angular's change detection strategies and immutable data structures.

Chapter 6, Dependency Injection in Angular, covers the dependency injection (DI) mechanism of Angular. We'll briefly discuss the positives of using DI in our projects by introducing it in the context of the framework. The second step in our journey is how to configure injectors using Angular modules; we'll also explain the injectors hierarchy and the visibility of the registered providers. In order to enforce a better separation of concerns, we'll take a look at how we can inject services carrying the business logic of our application in our directives and components.

Chapter 7, Working with the Angular Router and Forms, explains the basics of routing in Angular. We will take a look at how we can define different routes and implement the components associated with them that are displayed on route change. After that, we'll explain how to develop template-driven forms with built-in and custom validation. Finally, we'll explain how we can use two-way data-binding in Angular.

Chapter 8, Explaining Pipes and Communicating with RESTful Services, helps us take a deep dive into the Angular's forms module by developing a model-driven (reactive) form, combining it with the HTTP module. We'll take a look at some advanced features of the new component-based router and see how we can use and develop custom stateful and stateless pipes.

Chapter 9, Tooling and Development Experience, goes one step further, describing how to use web workers for performance-sensitive applications. Then, we'll learn to build SEO-friendly applications with server-side rendering. After that, we'll take a look at how to bootstrap a project as quickly as possible. Finally, we will learn what Ahead-of-Time (AOT) compilation is and how to use it.

Unlock full access

Continue reading for free

A Packt free trial gives you instant online access to our library of over 7000 practical eBooks and videos, constantly updated with the latest in tech
bookmark search playlist font-size

Change the font size

margin-width

Change margin width

day-mode

Change background colour

Close icon Search
Country selected

Close icon Your notes and bookmarks

Delete Bookmark

Modal Close icon
Are you sure you want to delete it?
Cancel
Yes, Delete