Running FCM on IP stops Angular rendering
- Lenguaje dominante
- TypeScript
- Estrellas
- 7.8k
- Forks
- 2.2k
- Merge medio
- 22 h 28 min
- PR fusionados (30 d)
- 6
Descripción
I need to sometimes run my app on IP for mobile testing etc, and this used to work fine in Angular 16 since firebase would just ignore IPs but now, since Angular 20, I get:
TypeError: Cannot read properties of undefined (reading 'addEventListener')
eventually failing with
FirebaseError: Messaging: This browser doesn't support the API's required to use the Firebase SDK. (messaging/unsupported-browser).
But not before it halts the whole app and stops it rendering.
This should just not do anything when it detect a none 127.0.0.1 IP as it did before, seems like there has been a regression bug somewhere.
Specifically the issue provider is:
provideMessaging(() => getMessaging()),
Guía de contribución
Línea de trabajo
Comienza en el punto de entrada provideMessaging(() => getMessaging()) y reproduce el problema mientras sirves la app en una IP distinta de 127.0.0.1. Rastrea el fallo de inicialización que provoca el unsupported-browser error; se considera terminado cuando la app continúa renderizándose sin que Firebase Messaging la detenga en ese entorno.
Escrito por el modelo de indexación a partir del texto del issue.
Evaluación
- Stack tecnológico
- angular, firebase, typescript
- Área
- frontend
- Tipo de issue
- Error
- Dificultad
- 3/5
- Tiempo estimado
- 1-2 días
- Estado de actividad
- Estancado
- Claridad
- Bastante claro
- Aptitud para principiantes
- 42/100