In our book list view again, let’s look at a mechanism to filter the records that are returned from the REST API. Instead of only being able to show the full list of books, our application will also have the ability to selectively query the database to only display books that meet the search criteria.

About the application

In this application, we’ll look at how we can apply a filter when displaying book records. We want to filter out the books so that only relevant books, related to a chosen field, appear in the book list. For that, we have a BooksFilterVu component that provides our application with certain fields to filter out the relevant books.

This is what the application looks like:

Note: To log in, use the username admin and password 123.

Get hands-on with 1400+ tech skills courses.