I'm new to react native and I would like to fetch data from an API, so I can place those values in a constructor.
To know how to fetch data, I'm using this URL: (https://reactnative.dev/docs/network) (I'm also using this for testing the app)
Now I know how to put the data into a flatlist, but I want to put them in a constructor.
The reason for this, is because I want to check if some data in the json file has a certain value. I've been trying to do this for a week, but can't figure it out.
I know how to make a constructor, as I did some exercises with that. The constructor seems to be working with mock-data. But now I need the API data.
If anyone can help me with this, I would really be gratefull.