I have a module pulling a JSON feed into Drupal 8 using the Migrate API. However, one of the values in the JSON is an array.
For example, coordinates
:
{
"data": [
{
"id": "id:1",
"position": {
"coordinates": [
24.932974,
60.168495
],
"type": "Point"
},
...
},
{
"id": "id:2",
"position": {
"coordinates": [
24.94416,
60.18831
],
"type": "Point"
},
...
},
...
What sort of field selector is needed to get coordinates
?
If I use selector: position/coordinates
I get 24.932974.
How would I get the second one: 60.168495?
Should the
extract
plugin be used here?