ReactJS – useState object loses getters when it is updated
I have a useState initialized to an object of type ExampleObject
. This class has many properties (also nested) that make use of javascript’s getters and setters. I use the getters all around my code in order to access the useState’s properties: