-
Notifications
You must be signed in to change notification settings - Fork 0
Sample State
BillTheDev edited this page Feb 24, 2022
·
9 revisions
{
entities: {
users: {
1: {
id: 1,
username: 'WillTheSongSmith',
email: '[email protected]',
avatar: 'http://the.img/here',
},
2: {
id: 2,
username: 'CousinCarlTune',
email: '[email protected]',
avatar: 'http://the.img/here2',
},
3: {
id: 3,
username: 'JeffTheJazziest',
email: '[email protected]',
avatar: 'http://the.img/here3',
},
4: {
id: 4,
username: 'BeatsBeingButler',
email: '[email protected]',
avatar: 'http://the.img/here4',
}
},
genres: {
1: {
id: 1,
name: 'rock'
},
2: {
id: 2,
name: 'pop'
},
3: {
id: 3,
name: 'indie'
},
4: {
id: 4,
name: 'hip-hop'
},
5: {
id: 5,
name: 'R&B'
}
},
artists: {
1: {
id: 1,
name: 'Young the Giant',
genreId: 1,
avatar: 'http://the.img/here4'
},
2: {
id: 2,
name: 'Childish Gambino',
genreId: 4,
avatar: 'http://the.img/here5'
},
3: {
id: 3,
name: 'Lizzo',
genreId: 2,
avatar: 'http://the.img/here6'
},
4: {
id: 4,
name: 'Black Pumas',
genreId: 5,
avatar: 'http://the.img/here7'
},
5: {
id: 5,
name: 'Vampire Weekend',
genreId: 3,
avatar: 'http://the.img/here7'
}
},
albums: {
1: {
id: 1,
title: 'Home of the Strange',
artistId: 1
},
2: {
id: 2,
title: '3.15.20',
artistId: 2
},
3: {
id: 3,
title: 'Good as Hell',
artistId: 3
},
4: {
id: 4,
title: 'Black Pumas',
artistId: 4
},
5: {
id: 5,
title: 'Father of the Bride',
artistId: 5
}
},
songs: {
1: {
id: 1,
title: '19.10',
albumId: 2,
mediaUrl: 'https://here.song/1'
},
2: {
id: 2,
title: 'Colors',
albumId: 4,
mediaUrl: 'https://here.song/2'
},
3: {
id: 3,
title: 'Good as Hell',
albumId: 3,
mediaUrl: 'https://here.song/3'
},
4: {
id: 4,
title: 'Harmony Hall',
albumId: 5,
mediaUrl: 'https://here.song/4'
},
5: {
id: 5,
title: 'Something to Believe In',
albumId: 1,
mediaUrl: 'https://here.song/5'
}
},
playlists: {
1: {
id: 1,
title: 'Poolside',
art: 'https://the.artwork/1',
creatorId: 2
},
2: {
id: 2,
title: 'Nighttime Boogie',
art: 'https://the.artwork/2',
creatorId: 4
},
},
playlists_songs: {
1: {
id: 1,
playlistId: 1,
songId: 1
},
2: {
id: 2,
playlistId: 1,
songId: 2
},
3: {
id: 3,
playlistId: 2,
songId: 1
},
4: {
id: 4,
playlistId: 2,
songId: 5
}
},
likes: {
1: {
id: 1,
userId: ,
likeableId: ,
likeableType:
},
2: {
id: 1,
userId: ,
likeableId: ,
likeableType:
},
3: {
id: 1,
userId: ,
likeableId: ,
likeableType:
},
4: {
id: 1,
userId: ,
likeableId: ,
likeableType:
}
}
},
ui: {
load: true/false,
modalSplash: true/false
},
errors: {
login: ['Incorrect username / password'],
playlistForm: ['Title / songlist can't be empty'],
},
session: { }
}Note: review likable, UI, errors, and session