Your data can sort, but your drop-down doesn't reflect it. To correct this, you need to implement a NgClass directive and turn on the Bootstrap 'active' class to highlight the display.
- [Instructor] Next up, let's work on…getting these drop downs to visually update,…depending on the value of the variables…that we just created in add components.…So we wanted to track this orderBy and orderType.…Now to do that,…we're going to go sort of backwards from this component…into the component that has this search right here.…So, we already have these variables created,…but in the add_component.html,…we need to pass them along to our search component.…
So right here, we're going to just say,…use the orderBy variable…and pass it along…to the sub component…and do the same thing for the orderType variables.…Just pass it along into the sub component…and let's go ahead and make this bigger.…So now that we have them in the sub component,…we need to capture it into the search component.…So what we need to do here is set this up as an input…and just like we output the events,…we're going to input a couple of items here.…
So this is going to setup this input decorator here…and bring the variable called orderBy…and then also orderType.…
- Building custom Angular projects
- Working with subcomponents
- Adding icons
- Adding search functionality
- Using lifecycle methods
- Managing list data
- Indexing your data
- Updating records
Skill Level Intermediate
Using the exercise files1m 43s
1. Building Custom Angular Projects
2. Working with Subcomponents
3. Creating More Subcomponents
Managing form submission8m 33s
4. Managing List Data
Next steps1m 8s
- Mark as unwatched
- Mark all as unwatched
Are you sure you want to mark all the videos in this course as unwatched?
This will not affect your course history, your reports, or your certificates of completion for this course.Cancel
Take notes with your new membership!
Type in the entry box, then click Enter to save your note.
1:30Press on any video thumbnail to jump immediately to the timecode shown.
Notes are saved with you account but can also be exported as plain text, MS Word, PDF, Google Doc, or Evernote.