diff --git a/aio/content/examples/property-binding/src/app/item.ts b/aio/content/examples/property-binding/src/app/item.ts index 53bcca4514..442f22b900 100644 --- a/aio/content/examples/property-binding/src/app/item.ts +++ b/aio/content/examples/property-binding/src/app/item.ts @@ -1,5 +1,5 @@ // #docregion item-class -export class Item { +export interface Item { id: number; name: string; } diff --git a/aio/content/tutorial/toh-pt1.md b/aio/content/tutorial/toh-pt1.md index 65d5092a49..9d250dd7ad 100644 --- a/aio/content/tutorial/toh-pt1.md +++ b/aio/content/tutorial/toh-pt1.md @@ -67,17 +67,17 @@ So add an `` element to the `AppComponent` template file, just below Assuming that the CLI `ng serve` command is still running, the browser should refresh and display both the application title and the hero name. -## Create a Hero class +## Create a Hero interface A real hero is more than a name. -Create a `Hero` class in its own file in the `src/app` folder. +Create a `Hero` interface in its own file in the `src/app` folder. Give it `id` and `name` properties. -Return to the `HeroesComponent` class and import the `Hero` class. +Return to the `HeroesComponent` class and import the `Hero` interface. Refactor the component's `hero` property to be of type `Hero`. Initialize it with an `id` of `1` and the name `Windstorm`.