- Популярные видео
- Авто
- Видео-блоги
- ДТП, аварии
- Для маленьких
- Еда, напитки
- Животные
- Закон и право
- Знаменитости
- Игры
- Искусство
- Комедии
- Красота, мода
- Кулинария, рецепты
- Люди
- Мото
- Музыка
- Мультфильмы
- Наука, технологии
- Новости
- Образование
- Политика
- Праздники
- Приколы
- Природа
- Происшествия
- Путешествия
- Развлечения
- Ржач
- Семья
- Сериалы
- Спорт
- Стиль жизни
- ТВ передачи
- Танцы
- Технологии
- Товары
- Ужасы
- Фильмы
- Шоу-бизнес
- Юмор
Custom NgRX Data Service: Connecting Firebase & Overriding Defaults | NgRx Course #87
In this lecture, we tackle the biggest hurdle in making NgRx Data work with real-world APIs: overriding the default URL behavior.
By default, NgRx Data looks for an API at root/api/courses. Since our data lives on Firebase, we need to tell NgRx Data to ignore its "smart" defaults and use our custom logic instead. We achieve this by building a Custom Data Service.
We create a Course Data Service that extends the DefaultDataService. This allows us to surgically override methods like getAll() while keeping the rest of the NgRx Data "magic" intact. We'll also walk through the essential step of registering this custom service in the AppModule so NgRx knows exactly when to use it.
What you will learn in this video:
✔️ The "Default Data Service" Concept: Why we need a middleman between our Entity Service and the server.
✔️ Overriding getAll(): Moving our Firebase fetching logic (mapping keys to IDs) into the NgRx Data flow.
✔️ Dependency Injection: Handling HttpClient and the HttpUrlGenerator in the constructor.
✔️ Service Registration: Using the EntityDataService.registerService() method inside the AppModule constructor.
✔️ Firebase Integration: Ensuring our specific .json endpoints and database URLs are respected.
✔️ End-to-End Verification: Watching the Network tab switch from a 404 to a successful Firebase fetch!
💡 By the end of this video, your Angular application will successfully load and display courses directly from Firebase using the power of NgRx Data.
👉 Perfect for Angular developers moving from beginner to advanced state management.
📌 This video is part of the Complete Angular NgRx Course. Stay tuned for the next lecture where we dive into the actual implementation! Subscribe and turn on notifications 🔔 to master the full NgRx ecosystem.
⏱️ Timestamps
00:00 The Problem: Why /api/courses is failing
01:30 Introduction to EntityDataService
02:40 Step 1: Creating the CourseDataService file
04:15 Constructor Setup: Injecting HttpClient and HttpUrlGenerator
06:30 Step 2: Overriding the getAll() method with Firebase logic
08:45 Mapping Firebase objects to the Course interface
10:00 Step 3: Registering the service in AppModule
12:15 Final Test: Successful data fetch in the UI
#Angular #NgRx #NgRxData #Firebase #WebDevelopment #Angular16 #StateManagement #TypeScript #APIIntegration #FrontendArchitecture #RxJS #Redux
Видео Custom NgRX Data Service: Connecting Firebase & Overriding Defaults | NgRx Course #87 канала procademy
By default, NgRx Data looks for an API at root/api/courses. Since our data lives on Firebase, we need to tell NgRx Data to ignore its "smart" defaults and use our custom logic instead. We achieve this by building a Custom Data Service.
We create a Course Data Service that extends the DefaultDataService. This allows us to surgically override methods like getAll() while keeping the rest of the NgRx Data "magic" intact. We'll also walk through the essential step of registering this custom service in the AppModule so NgRx knows exactly when to use it.
What you will learn in this video:
✔️ The "Default Data Service" Concept: Why we need a middleman between our Entity Service and the server.
✔️ Overriding getAll(): Moving our Firebase fetching logic (mapping keys to IDs) into the NgRx Data flow.
✔️ Dependency Injection: Handling HttpClient and the HttpUrlGenerator in the constructor.
✔️ Service Registration: Using the EntityDataService.registerService() method inside the AppModule constructor.
✔️ Firebase Integration: Ensuring our specific .json endpoints and database URLs are respected.
✔️ End-to-End Verification: Watching the Network tab switch from a 404 to a successful Firebase fetch!
💡 By the end of this video, your Angular application will successfully load and display courses directly from Firebase using the power of NgRx Data.
👉 Perfect for Angular developers moving from beginner to advanced state management.
📌 This video is part of the Complete Angular NgRx Course. Stay tuned for the next lecture where we dive into the actual implementation! Subscribe and turn on notifications 🔔 to master the full NgRx ecosystem.
⏱️ Timestamps
00:00 The Problem: Why /api/courses is failing
01:30 Introduction to EntityDataService
02:40 Step 1: Creating the CourseDataService file
04:15 Constructor Setup: Injecting HttpClient and HttpUrlGenerator
06:30 Step 2: Overriding the getAll() method with Firebase logic
08:45 Mapping Firebase objects to the Course interface
10:00 Step 3: Registering the service in AppModule
12:15 Final Test: Successful data fetch in the UI
#Angular #NgRx #NgRxData #Firebase #WebDevelopment #Angular16 #StateManagement #TypeScript #APIIntegration #FrontendArchitecture #RxJS #Redux
Видео Custom NgRX Data Service: Connecting Firebase & Overriding Defaults | NgRx Course #87 канала procademy
Комментарии отсутствуют
Информация о видео
2 ноября 2025 г. 21:00:25
00:14:44
Другие видео канала




















