Can you add a server to this example?
So that we can do something like node app.js and test it locally?
You can run the firebase function locally: https://github.com/invokemedia/vue-push-notification-example/blob/0aa4d86619f2233113c9decb20a53b5bc8e1bae6/firebase-function/functions/package.json#L5
There are checks in the function to allow this.
Change to firebase functions folder and run npm run start which will trigger the function as if it was live in firebase
Thanks. However, why am I getting this error "registration ids field cannot be empty" when I run npm run start?
I am guessing your database is empty and you have not added any subscribers to it
Are you referring to the Firebase realtime database? How do I add subscribers to it?