Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

FCM: `apns.fcmOptions.imageUrl` and `notification.imageUrl` not rendering images for < iOS 18 and < ipadOS 18

Abierto
#2,807 3 comentarios 0 reacciones 1 asignado Ver en GitHub

@chong-shao ya está trabajando en esto.

Desde el 19/12/2024.

Evaluación

Este issue todavía no se ha evaluado.

Descripción

api: messaging
[REQUIRED] Step 2: Describe your environment
  • Operating System version: < iOS 18, < ipadOS 18 (client), Ubuntu 14.04.6 LTS (server)
  • Firebase SDK version: 12.0.0
  • Firebase Product: Cloud messaging (FCM)
  • Node.js version: 16 (LTS)
  • Yarn version: 1.22.22
[REQUIRED] Step 3: Describe the problem
  1. Images do not render on iOS < 18 and ipadOS < 18 devices, when sending a payload with apns.fcmOptions.imageUrl or notification.imageUrl. I thought it might be related to image size so I sent an image with a size of 400 bytes but still no luck.

  2. Slightly unrelated, but the docs state to use apns.fcmOptions.image (source) whilst the TypeScript interface declares apns.fcmOptions.imageUrl (code). I've tried setting an ignore rule for the compiler to use apns.fcmOptions.image in the payload, whilst this also renders images for iOS 18 and ipadOS 18, it still doesn't render for iOS 17 and ipadOS 17 devices.

Steps to reproduce:

What happened? How can we make the problem occur?
This could be a description, log/console output, etc.

  1. Create notification payload with image url set as apns.fcmOptions.imageUrl or notification.imageUrl
  2. Send notification (using sendEachForMulticast())
  3. Observe received notification on iOS 18 and ipadOS 18 devices, image successfully displayed on both
  4. Observe received notification on iOS 17 and ipadOS 17 devices, image not displayed on either

Example: Successful notification on ios 18 with image

Screenshot 2024-12-12 at 11 31 42
Relevant Code:

Example payload

{
  apns: {
    fcmOptions: {
      imageUrl: "imageUrl"
    },
    payload: {
      aps: {
        alert: {
          body: "body"
        },
        mutableContent: true
      }
    }
  }
}
Lenguaje dominante
TypeScript
Estrellas
1.7k
Forks
419
Merge medio
4 d 20 h
PR fusionados (30 d)
16

Guía de contribución

Abrir la guía de contribución

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de firebase/firebase-admin-node

Todos los issues de firebase/firebase-admin-node

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.