update vs set firebase firestore code example
Example: firebase set vs update
firebase.database().ref().child('/posts/' + newPostKey)
.set({ title: "New title", body: "This is the new body" });
firebase.database().ref().child('/posts/' + newPostKey)
.set({ title: "New title", body: "This is the new body" });