I list the car brands as follows. I keep the cars the user likes in a separate table. How can I list the cars that the user likes with their features? I am using firebase realtime database.
{
cars:{
{"id" : 1, "title" : "BMW"},
{"id" : 2, "title" : "Toyota"}
},
likes:{
"1":{user1: true, user2: true},
"2":{user1: true},
}
}
How should my table JSON layout be?
I studied the Many to Many relationship in Firebase question, but I could not understand how to get the car information.