Pass Data to Components with Inputs

InstructorSam Julien

Share this video with your friends

Send Tweet

We can pass data between components in Angular using inputs. Let's learn how.

Masabi
~ 3 years ago

The 3rd video was confusing. It misses steps and lacks continuation from the previous video. The habit-detail component seems to have been removed and when I followed the steps to display the habit-list component in the browser (0:20), it wasn't working. No information was given in the video to add <app-habit-list></app-habit-list> to the app.component it was glossed over. For someone trying to grasp basics this step was fundamentally important. Thankfully the "view code" option saved the day, but even this wasn't discovered until after over 40 minutes of rewinding the steps in the video and scrutiny of my own mirrored syntax. Frustrating.

Masabi
~ 3 years ago

The 3rd video also threw me when discussing the @Input "decorator" (3:02) Whilst mentioning that your editor "pulls from the angular core package" What this actually means is that Input should be defined within the import list at the very top on line 1. If your editor doesn't do this automatically (like mine) the compilation will fail and nothing will display in the browser.

~ 2 years ago

Je suis totalement d'accord avec Masabi.