• Learning Angular
  • Architecture
  • Displaying Data
  • Dependency Injection
  • Template Syntax
  • Introduction
  • 0. The Starter App
  • 1. The Hero Editor
  • 2. Master/Detail
  • 3. Multiple Components
  • 4. Services
  • Attribute Directives
  • Component Styles
  • Hierarchical Injectors
  • HTTP Client
  • Lifecycle Hooks
  • Structural Directives
  • Components Gallery
  • Cheat Sheet
  • Community and Support
  • API Documentation

On this page

The end game.

new_releases We're currently in the progress of migrating this site from Angular version 5.3.1 to 7.0.0. Package versions might be out-of-date or inconsistent! Visit the repo for more info.

Tutorial: Tour of Heroes 6.0

The grand plan for this tutorial is to build an app that helps a staffing agency manage its stable of heroes.

The Tour of Heroes app covers the core fundamentals of Angular. You’ll build a basic app that has many of the features you’d expect to find in a full-blown, data-driven app: acquiring and displaying a list of heroes, editing a selected hero’s detail, and navigating among different views of heroic data. You’ll learn the following:

  • Use built-in directives to show and hide elements and display lists of hero data.
  • Create components to display hero details and show an array of heroes.
  • Use one-way data binding for read-only data.
  • Add editable fields to update a model with two-way data binding.
  • Bind component methods to user events, like keystrokes and clicks.
  • Enable users to select a hero from a master list and edit that hero in the details view.
  • Format data with pipes.
  • Create a shared service to assemble the heroes.
  • Use routing to navigate among different views and their components.

You’ll learn enough core Angular to get started and gain confidence that Angular can do whatever you need it to do. You’ll cover a lot of ground at an introductory level, and you’ll find many links to pages with greater depth.

When you’re done with this tutorial, the app will look like this live example ( view source ) .

Here’s a visual idea of where this tutorial leads, beginning with the “Dashboard” view and the most heroic heroes:

Output of heroes dashboard

You can click the two links above the dashboard (“Dashboard” and “Heroes”) to navigate between this Dashboard view and a Heroes view.

If you click the dashboard hero “Magneta,” the router opens a “Hero Details” view where you can change the hero’s name.

Details of hero in app

Clicking the “Back” button returns you to the Dashboard. Links at the top take you to either of the main views. If you click “Heroes,” the app displays the “Heroes” master list view.

Output of heroes list app

When you click a different hero name, the read-only mini detail beneath the list reflects the new choice.

You can click the “View Details” button to drill into the editable details of the selected hero.

The following diagram captures all of the navigation options.

View navigations

Here’s the app in action:

You’ll build the Tour of Heroes app, step by step. Each step is motivated with a requirement that you’ve likely met in many apps. Everything has a reason.

Along the way, you’ll become familiar with many of the core fundamentals of Angular.

Tour of Heroes app and tutorial

In this tutorial, you build your own application from the ground up, providing experience with the typical development process, as well as an introduction to basic app-design concepts, tools, and terminology.

If you're completely new to Angular, you might want to try the Try it now quick-start application first. It is based on a ready-made partially-completed project, which you can examine and modify in the StackBlitz interactive development environment, where you can see the results in real time.

The "Try it" tutorial covers the same major topics—components, template syntax, routing, services, and accessing data using HTTP—in a condensed format, following the most current best practices.

This Tour of Heroes tutorial shows you how to set up your local development environment and develop an application using the Angular CLI tool , and provides an introduction to the fundamentals of Angular.

The Tour of Heroes application that you build helps a staffing agency manage its stable of heroes. The application has many of the features you'd expect to find in any data-driven application. The finished application acquires and displays a list of heroes, edits a selected hero's detail, and navigates among different views of heroic data.

You will find references to and expansions of this application domain in many of the examples used throughout the Angular documentation, but you don't necessarily need to work through this tutorial to understand those examples.

By the end of this tutorial you will be able to do the following:

  • Use built-in Angular directives to show and hide elements and display lists of hero data.
  • Create Angular components to display hero details and show an array of heroes.
  • Use one-way data binding for read-only data.
  • Add editable fields to update a model with two-way data binding.
  • Bind component methods to user events, like keystrokes and clicks.
  • Enable users to select a hero from a master list and edit that hero in the details view.
  • Format data with pipes .
  • Create a shared service to assemble the heroes.
  • Use routing to navigate among different views and their components.

You'll learn enough Angular to get started and gain confidence that Angular can do whatever you need it to do.

After completing all tutorial steps, the final application will look like this: .

What you'll build

Here's a visual idea of where this tutorial leads, beginning with the "Dashboard" view and the most heroic heroes:

You can click the two links above the dashboard ("Dashboard" and "Heroes") to navigate between this Dashboard view and a Heroes view.

If you click the dashboard hero "Magneta," the router opens a "Hero Details" view where you can change the hero's name.

Clicking the "Back" button returns you to the Dashboard. Links at the top take you to either of the main views. If you click "Heroes," the application displays the "Heroes" master list view.

When you click a different hero name, the read-only mini detail beneath the list reflects the new choice.

You can click the "View Details" button to drill into the editable details of the selected hero.

The following diagram captures all of the navigation options.

Here's the application in action:

© 2010–2021 Google, Inc. Licensed under the Creative Commons Attribution License 4.0. https://v12.angular.io/tutorial

This website requires JavaScript.

Tutorial: Tour of Heroes

The Tour of Heroes tutorial covers the fundamentals of Angular. In this tutorial you will build an app that helps a staffing agency manage its stable of heroes.

This basic app has many of the features you'd expect to find in a data-driven application. It acquires and displays a list of heroes, edits a selected hero's detail, and navigates among different views of heroic data.

By the end of the tutorial you will be able to do the following:

  • Use built-in Angular directives to show and hide elements and display lists of hero data.
  • Create Angular components to display hero details and show an array of heroes.
  • Use one-way data binding for read-only data.
  • Add editable fields to update a model with two-way data binding.
  • Bind component methods to user events, like keystrokes and clicks.
  • Enable users to select a hero from a master list and edit that hero in the details view.
  • Format data with pipes.
  • Create a shared service to assemble the heroes.
  • Use routing to navigate among different views and their components.

You'll learn enough Angular to get started and gain confidence that Angular can do whatever you need it to do.

After completing all tutorial steps, the final app will look like this .

What you'll build

Here's a visual idea of where this tutorial leads, beginning with the "Dashboard" view and the most heroic heroes:

You can click the two links above the dashboard ("Dashboard" and "Heroes") to navigate between this Dashboard view and a Heroes view.

If you click the dashboard hero "Magneta," the router opens a "Hero Details" view where you can change the hero's name.

Clicking the "Back" button returns you to the Dashboard. Links at the top take you to either of the main views. If you click "Heroes," the app displays the "Heroes" master list view.

When you click a different hero name, the read-only mini detail beneath the list reflects the new choice.

You can click the "View Details" button to drill into the editable details of the selected hero.

The following diagram captures all of the navigation options.

Here's the app in action:

© 2010–2019 Google, Inc. Licensed under the Creative Commons Attribution License 4.0. https://v7.angular.io/tutorial

This website requires JavaScript.

IMAGES

  1. Tour of Heroes App and Tutorial

    angular tour of heroes deutsch

  2. Angular: Tour of Heroes tutorial

    angular tour of heroes deutsch

  3. Tour of Heroes Application and Tutorial

    angular tour of heroes deutsch

  4. Tour of Heroes (Angular Example)

    angular tour of heroes deutsch

  5. Introduction to Angular: Tour of Heroes

    angular tour of heroes deutsch

  6. GitHub

    angular tour of heroes deutsch

VIDEO

  1. Curse of Naxxramas

  2. Angular / Tour of Heroes ( partie 1 ) : créer le projet et premiers pas

  3. Nx After Dark: Extracting features into workspace libraries

  4. Tale of a Hero Trailer Deutsch

  5. THE LEGEND OF HEROES: TRAILS IN THE SKY 3rd #96

  6. THE LEGEND OF HEROES: TRAILS IN THE SKY 3rd #49

COMMENTS

  1. Angular

    This Tour of Heroes tutorial provides an introduction to the fundamentals of Angular and shows you how to:. Set up your local Angular development environment. Use the Angular CLI to develop an application.; The Tour of Heroes application that you build helps a staffing agency manage its stable of heroes. The application has many of the features that you'd expect to find in any data-driven ...

  2. Angular

    Tour of Heroeslink. Tour of Heroes helps you gain confidence that Angular can do whatever you need it to do by showing you how to: Use Angular directives to show and hide elements and display lists of hero data. Create Angular components to display hero details and show an array of heroes. Use one-way data binding for read-only data.

  3. Angular

    Router tutorial: tour of heroes. This tutorial provides an extensive overview of the Angular router. In this tutorial, you build upon a basic router configuration to explore features such as child routes, route parameters, lazy load NgModules, guard routes, and preloading data to improve the user experience. For a working example of the final ...

  4. awoerz/Angular-17-Tour-Of-Heroes

    Angular 17 has breaking changes with the Tour of Heroes tutorial on the original Angular.io docs site. My goal is to recreate the tutorial but using Angular 17 and standalone components. - awoerz/Angular-17-Tour-Of-Heroes

  5. Angular

    Angular is a platform for building mobile and desktop web applications. Join the community of millions of developers who build compelling user interfaces with Angular. ... Expand the Tour of Heroes application to display a list of heroes. Allow users to select a hero and display the hero's details.

  6. Angular Example

    styles.css. angular.json. package.json. Using StackBlitz at work? Join our livestream on May 1 to learn about how StackBlitz can help your team collaborate more effectively. View event. Console. Clear on reload. Angular Example - Tour of Heroes: Part 6.

  7. Tour of Heroes Application and Tutorial

    This Tour of Heroes tutorial provides an introduction to the fundamentals of Angular and shows you how to:. Set up your local Angular development environment. Use the Angular CLI to develop an application.; The Tour of Heroes application that you build helps a staffing agency manage its stable of heroes. The application has many of the features that you'd expect to find in any data-driven ...

  8. Angular

    heroes.component.html (HeroDetail binding) content_copy <app-hero-detail [hero] = "selectedHero" ></app-hero-detail> [hero]="selectedHero" is an Angular property binding. It's a one-way data binding from the selectedHero property of the HeroesComponent to the hero property of the target element, which maps to the hero property of the HeroDetailComponent.. Now when the user clicks a hero in the ...

  9. Tutorial: Tour of Heroes

    Tutorial: Tour of Heroes. The grand plan for this tutorial is to build an app that helps a staffing agency manage its stable of heroes. The Tour of Heroes app covers the core fundamentals of Angular. You'll build a basic app that has many of the features you'd expect to find in a full-blown, data-driven app: acquiring and displaying a list ...

  10. Angular

    src/app/hero.service.ts content_copy getHeroes (): Hero [] {return HEROES;}. Provide the HeroServicelink. You must make the HeroService available to the dependency injection system before Angular can inject it into the HeroesComponent by registering a provider.A provider is something that can create or deliver a service. In this case, it instantiates the HeroService class to provide the service.

  11. Tour of Heroes App and Tutorial

    This Tour of Heroes tutorial shows you how to set up your local development environment and develop an application using the Angular CLI tool, and provides an introduction to the fundamentals of Angular.. The Tour of Heroes application that you build helps a staffing agency manage its stable of heroes. The application has many of the features you'd expect to find in any data-driven application.

  12. Angular

    content_copy ng new angular-tour-of-heroes; ng new prompts you for information about features to include in the initial project. Accept the defaults by pressing the Enter or Return key. ng new installs the necessary npm packages and other dependencies that Angular requires. This can take a few minutes. ng new also creates the following workspace and starter project files:

  13. Angular

    Angular is a platform for building mobile and desktop web applications. Join the community of millions of developers who build compelling user interfaces with Angular.

  14. Introduction to Angular: Tour of Heroes

    Become a Patreon! Your continued support enables me to continue creating free content: https://www.patreon.com/PaulHallidayIntroduction to Angular: Tour of H...

  15. Tutorial: Tour of Heroes

    Tutorial: Tour of Heroes The Tour of Heroes tutorial covers the fundamentals of Angular. In this tutorial you will build an app that helps a staffing agency manage its stable of heroes. This basic app has many of the features you'd expect to find in a data-driven application. It acquires and displays a list of heroes, edits a selected hero's detail, and navigates among different views of ...

  16. Angular

    The template presents a grid of hero name links.. The *ngFor repeater creates as many links as are in the component's heroes array.; The links are styled as colored blocks by the dashboard.component.css.; The links don't go anywhere yet. The class is like the HeroesComponent class.. It defines a heroes array property; The constructor expects Angular to inject the HeroService into a private ...

  17. Angular's sample app Tour of Heroes in v16

    CSS 20.9%. HTML 9.2%. Angular's sample app Tour of Heroes in v16. Contribute to dyave/angular-toh-16 development by creating an account on GitHub.

  18. Angular

    A real hero is more than a name. Create a Hero interface in its own file in the src/app directory . Give it id and name properties. src/app/hero.ts. content_copy. export interface Hero {. id: number; name: string; } Return to the HeroesComponent class and import the Hero interface.

  19. Feeling Down After Going Through Angular's Tour Of Heroes

    First of all, it's okay to feel scared when learning, that's part of the journey. You shouldn't do a tour of heroes before doing "Getting started" and "Understanding angular". First, you need to know the basic concept and building blocks. Then when you learn the basic concepts then you can start with a tour of heroes.

  20. So I just finished the Tour of Heroes tutorial : r/angular

    The whole course is around 6.5 hours. Be patient. Watch it across multiple days. For one, you probably can't watch it in one go due to your work load. Secondly, you'll be able to digest information easier this way. The guy is a great teacher, who actually knows how to teach. He is a bit of a slow talker.

  21. GermanITCH/angular-tour-of-heroes

    Contribute to GermanITCH/angular-tour-of-heroes development by creating an account on GitHub.

  22. GitHub

    Run ng e2e to execute the end-to-end tests via a platform of your choice. To use this command, you need to first add a package that implements end-to-end testing capabilities.