becem-gharbi / nuxt-fcm

Firebase Cloud Messaging for Nuxt
MIT License
20 stars 2 forks source link

On Google Cloud Envirnoment Variables empty #18

Closed Ombuweb closed 1 month ago

Ombuweb commented 1 month ago

Please help. I'm getting the error: "Installations: Missing App configuration value: "projectId" (installations/missing-app-config-values)" when I deploy the app to Google Cloud. It seems that the Firebase config isn't being loaded from the environment in defineNuxtConfig

becem-gharbi commented 1 month ago

Hi, when loading firebaseConfig config object as env variable it should be parsed. This could be done either on build time via nuxt.config (check playground) or at runtime via matching env variables (recommended) [docs].

NUXT_PUBLIC_FCM_FIREBASE_CONFIG= {"apiKey": "___","authDomain": "__","projectId": "__","storageBucket": "___","messagingSenderId": "___","appId": "___"}