-
Notifications
You must be signed in to change notification settings - Fork 2.2k
-
Hi, I was wondering what are the equivalents to these methods in Angularfire v.7
- Firestore -
createId()
method which should create an id for a document to be created in Firestore - Messaging -
tokenChanges()
method which should return an observable emitting the token every time there is a change - Messaging -
message()
method which should return an observable emitting the push notifications from FCM.
I am migrating to v7 from v6 and I was not able to find equivalents for the methods above. Any help finding the new equivalents would be greatly appreciated.
Beta Was this translation helpful? Give feedback.
All reactions
Replies: 1 comment
-
From what I can tell, the createId
function is no longer available. However, looking at its source code, it seems like a pretty simple utility function that you can define yourself like so:
import { collection, doc } from '@angular/fire/firestore';
createId(): string {
return doc(collection(FIRESTORE_INSTANCE, '_')).id;
}
Beta Was this translation helpful? Give feedback.
All reactions
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment