-
Notifications
You must be signed in to change notification settings - Fork 0
/
dbschema.js
69 lines (68 loc) · 1.69 KB
/
dbschema.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
const db = {
users: [
{
userId: '5DJt1enbUGadQ3ANvv2oD7ZduOu2',
email: 'user@gmail.com',
handle: 'user',
createdAt: '2019-09-28T13:21:54.561Z',
imageUrl:
'https://firebasestorage.googleapis.com/v0/b/social-media-screams.appspot.com/o/80984110197.jpg?alt=media',
bio: 'Hello, my name is John Doe',
website: 'https://john.doe.com',
location: 'Lviv, UA'
}
],
screams: [
{
userHandle: 'user',
userImage:
'https://firebasestorage.googleapis.com/v0/b/social-media-screams.appspot.com/o/68644931927.jpg?alt=media',
body: 'First Scream !!!',
createdAt: '2019-09-28T13:09:45.853Z',
likeCount: 5,
commentCount: 2
}
],
comments: [
{
userHandle: 'user',
screamId: 's72HlZoK1tXqyGjL5Dai',
comment: 'First comment',
createdAt: '2019-09-28T13:10:50.853Z'
}
],
notifications: [
{
recipient: 'user',
sender: 'john',
read: 'true | false',
screamId: 'voNyMzKYZnkmkUDS4UPJ',
type: 'like | comment',
createdAt: '2019-09-28T13:16:05.853Z'
}
]
}
const userDetails = {
// Redux data
credentials: {
userId: '5DJt1enbUGadQ3ANvv2oD7ZduOu2',
email: 'user@gmail.com',
handle: 'user',
createdAt: '2019-09-28T13:21:54.561Z',
imageUrl:
'https://firebasestorage.googleapis.com/v0/b/social-media-screams.appspot.com/o/80984110197.jpg?alt=media',
bio: 'Hello, my name is John Doe',
website: 'https://john.doe.com',
location: 'Lviv, UA'
},
likes: [
{
userHandle: 'user',
screamId: 's72HlZoK1tXqyGjL5Dai'
},
{
userHandle: 'user',
screamId: 'voNyMzKYZnkmkUDS4UPJ'
}
]
}