I’ve decided to have the program grab the events from array, sort them by their unique ID, and put them into cumulative data structures which will be remembered throughout the course of the program.
Each time the API is queried, the newly returned JSON objects will again be sorted, checked for duplicated in the persistent structures.
Questions:
* when I grab the objects from their original JSON and place them in the persistent structure, how should I do it so as to not have the JSON stick around? JS Objects are passed via reference semantics. I worry that if I grab some but not all the objects from their original JSON, the entire JSON structure will persist, consuming resources. I think perhaps something like “clone” would solve this problem.
Never mind, Array.remove() will solve this fine.