From be5e75c8048d96964ad0872f773c2b103c720ec8 Mon Sep 17 00:00:00 2001 From: Sonu Kapoor Date: Thu, 13 Feb 2020 20:27:04 -0500 Subject: [PATCH] docs: change `item` to `items` to match the code (#35433) Closes #35368 PR Close #35433 --- aio/content/guide/template-syntax.md | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/aio/content/guide/template-syntax.md b/aio/content/guide/template-syntax.md index b197073594..7e7bd9b2d1 100644 --- a/aio/content/guide/template-syntax.md +++ b/aio/content/guide/template-syntax.md @@ -731,11 +731,11 @@ As you can see here, the `parentItem` in `AppComponent` is a string, which the ` The previous simple example showed passing in a string. To pass in an object, the syntax and thinking are the same. -In this scenario, `ListItemComponent` is nested within `AppComponent` and the `item` property expects an object. +In this scenario, `ListItemComponent` is nested within `AppComponent` and the `items` property expects an array of objects. -The `item` property is declared in the `ListItemComponent` with a type of `Item` and decorated with `@Input()`: +The `items` property is declared in the `ListItemComponent` with a type of `Item` and decorated with `@Input()`: @@ -748,7 +748,7 @@ specify a different item in `app.component.ts` so that the new item will render: -You just have to make sure, in this case, that you're supplying an object because that's the type of `item` and is what the nested component, `ListItemComponent`, expects. +You just have to make sure, in this case, that you're supplying an array of objects because that's the type of `items` and is what the nested component, `ListItemComponent`, expects. In this example, `AppComponent` specifies a different `item` object (`currentItem`) and passes it to the nested `ListItemComponent`. `ListItemComponent` was able to use `currentItem` because it matches what an `Item` object is according to `item.ts`. The `item.ts` file is where