I was looking for normalizr to align JSON API data formatted in standard JSON API format . Can someone point me to some examples of this? I specifically focus on how to handle the normalizr schema for resource object relationships (as defined by the JSON API standard). In the JSON API standard, there is a “relationship” property defined in a resource object, and then properties for each group of related objects. Here is an example of one product category in JSON API format with two related products:
{
"jsonapi": {
"version": "1.0"
},
"meta": {
"time": "0.006"
},
"data": [
{
"type": "category",
"id": "6",
"attributes": {
"name": "Odwalla"
},
"meta": {
"product_count": "0"
},
"relationships": {
"product": {
"data": [
{
"type": "product",
"id": "4785"
},
{
"type": "product",
"id": "4786"
}
]
}
}
}
],
"included": [
{
"type": "product",
"id": "4786",
"attributes": {
"name": "Strawberry & Banana Odwalla",
"description": null,
"price": "3.19",
"upc": ""
}
},
{
"type": "product",
"id": "4785",
"attributes": {
"name": "Blueberry Odwalla",
"description": null,
"price": "3.19",
"upc": ""
}
}
]
}
, , data.relationships.product.data, . , ; Flux/Redux?