Skip to content

Commit 178add9

Browse files
committed
chore: add initial common model interfaces
1 parent ebe6853 commit 178add9

2 files changed

Lines changed: 14 additions & 0 deletions

File tree

src/app/data/models/common/id.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
export interface HasId {
2+
/** Unique ID of this document. */
3+
id: string;
4+
}
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
import { Timestamp } from '@firebase/firestore';
2+
3+
export { HasId } from '../common/id';
4+
5+
export interface WithDbTimestampMetadata {
6+
/** Creation date of this document as a Firestore {@link Timestamp}. */
7+
createdAt: Timestamp;
8+
/** Last modification date of this document as a Firestore {@link Timestamp}. */
9+
lastModified: Timestamp;
10+
}

0 commit comments

Comments
 (0)