私はjs側からデータを取得しました。これは、このように見え
{
"selectionSet": {
"type": 1,
"selections": [
{
"name": {
"kind": "Name",
"value": "viewer"
},
"selectionSet": {
"type": 1,
"selections": [
{
"name": {
"kind": "Name",
"value": "avatarUrl"
},
"selectionSet": null
}
]
}
}
]
}
}
ます。selectionSet
selections
を定義するとき、型が のフィールドがあるのでselections
定義するべきだったようです。しかし、定義されている場合、定義する必要がありましたselectionSet
selectionSet
selectionSet
selections
誰かがOCamlスタイルで答えることができますか? この JSON 形式のデータをレコードに変換したいと考えています。