You've created a data model and interface. Now, use it to get data from your API. In this video, learn how to use an interface to fetch data from an API.
You might be wondering what should we do with the interface? … Well, here's what we're going to do. … We are going to make sure that our two methods, … get activity and get all activities … are returning the correct type of data. … Remember what I said earlier? … an observable is returned. … Now we're going to type cast this observable … and say, it is of type observable, and hit enter. … And this observable type is … of type activity, and hit enter. … Now at this point in time, … it is worth noting that I am leveraging … on Visual Studios ability to automatically … import specific things for me. … For example, if you look at line three and line four, … just by merely typing the observable, … Visual Studio Code was able to import … The same thing happened on line four, … was able to detect and import the activity interface for me. … you will need to manually write these lines of code. … The next thing we're going to go and do … our get activity function says … that it will be returning an observable of type activity, …
- Ionic 4.0 features
- Testing with Ionic Lab
- Designing a home page
- Generating services
- Consuming REST APIs
- Creating a data model
- Using Ionic DevApp
- Using Ionic Native
- Designing the profile page
- Sharing to social media
- Setting up Firebase
Skill Level Intermediate
Angular: Maintaining Applicationswith Emmanuel Henri44m 29s Intermediate
Angular: Progressive Web Appswith Maximiliano Firtman4h 40m Intermediate
1. Setting Up the Environment
2. Working with a Tab-Based Template
3. Preview App on Device with Ionic DevApp
Introduction to Ionic DevApp3m 57s
4. Working with UI Components
5. Working with Ionic Native
6. Connecting an App to Firebase Backend
7. Working with Complex Lists
Next steps2m 24s
- 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.