Scenario
We have a database that displays the following ratio:
- A
taghas a lotcampaigns - A
campaignhas a lottags - The relationship between
campaignsand tagsis represented by an associative entity calledcampaign_tag - The object
campaign_taghas an attribute.priority
Question
How can we implement normalizr (or any similar library) to create a smooth state of an application that takes into account our associative objects when our associative objects do not have unique identifiers / values?
Notes / Miscellaneous Thoughts
, , , " " " ". , :
{
entities: {
campaigns: {
'1': { id: 1, name: 'Ace', tags: [1, 2, 3] },
...
},
tags: {
'1': { id: 1, name: 'Example Tag', campaigns: [1, 2, 3] },
...
}
},
...
}
entities? ? . ?
, .