Complete the code to set a Firestore field to the server timestamp.
docRef.set({ createdAt: [1] })Use firebase.firestore.FieldValue.serverTimestamp() to set the field to the server's current time.
Complete the code to update a Firestore document's 'updatedAt' field with the server timestamp.
docRef.update({ updatedAt: [1] })Use firebase.firestore.FieldValue.serverTimestamp() to update with the server time.
Fix the error in the code to correctly set a Firestore field to the server timestamp.
docRef.set({ time: [1] })The correct method is firebase.firestore.FieldValue.serverTimestamp() to get the server timestamp placeholder.
Fill both blanks to create a Firestore document with 'createdAt' and 'updatedAt' fields set to server timestamps.
docRef.set({ createdAt: [1], updatedAt: [2] })Both fields should use firebase.firestore.FieldValue.serverTimestamp() to get server timestamps.
Fill all three blanks to update a Firestore document with 'lastLogin', 'lastLogout', and 'lastAction' fields set to server timestamps.
docRef.update({ lastLogin: [1], lastLogout: [2], lastAction: [3] })All fields should use firebase.firestore.FieldValue.serverTimestamp() to ensure server time is recorded.