How to determine the class of a parsed JSON string in JavaScript?

I have a JSON string that I converted using JSON.parse(String);. I need to verify the class it inherits from, specifically my custom class ‘Action’. However, I am unsure how to check this programmatically. For example, running the following code yields unexpected results:
action instanceof Action => false
typeof action => Object
.

yo Harry47, when u use JSON.prse, u get a plain object back, it doesn’t retain the class type. Gotta recreate it: pass it back into ur constructor, like let action = new Actin(parsedObj) once parsed. hope that helps!