The ________ method is used to parse a JSON string into a JavaScript object.

  • toJSON()
  • parseJSON()
  • JSON.parse()
  • stringToJSON()
The correct method to parse a JSON string into a JavaScript object is JSON.parse(). It takes a JSON string as input and returns a JavaScript object. The other options (toJSON(), parseJSON(), stringToJSON()) are not valid JSON parsing methods.
Add your answer
Loading...

Leave a comment

Your email address will not be published. Required fields are marked *