becem-gharbi / nuxt-fcm

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

Any way to pass firebaseConfig to firebase-messaging-sw.js? #6

Closed Joey-Emery closed 1 year ago

Joey-Emery commented 1 year ago

I really don't want to commit files into our git repo with configuration details in them, is there any way the SW JS file can use environment variables or have the configuration passed into it?

Thanks

becem-gharbi commented 1 year ago

Thanks very much for this brilliant idea, I just implemented it on v0.2.7.

Joey-Emery commented 1 year ago

Man you work fast, that's insane thank you! I wrote a node script to put all the config in from the environment variables but your solution seems much slicker, really appreciate it