This is my context provider. Within the component, I fetch local JSON data. The JSON data looks something like this:
[
{
"name": "Alan",
"ticker": [
"AAPL",
"MSFT",
"GOOG",
"FB"
]
},
{
"name": "Madison",
"ticker": [
"TSLA",
"AAPL",
"V"
]
},
etc...
]
So it is just an array of objects. If I were to console log resp.json() it would come out good. If I console log data it would come out with the array of objs. which is good. BUT the moment I try using setProfile(data), the application going bonkers. Let me show you what happens when I try setting the profile with the data.

I'm assuming that this is an infinite fetch loop. Not sure honestly why this is happening when I try to setProfile(data). If there is another way of doing this please let me know. All I'm trying to do is get all the profile data in the profile context so I can use it in my other components. For example I've created a dropdown which display all the names in the json file.
