Began to study AJAX recently. To work with the server response as with JSON, I usually indicated in the parameters of an AJAX request the corresponding type of response: dataType: 'json' .
However, looking at some answers to the questions here, I saw that many use the default type of response, and if you want to work with the answer in JSON format, use the functions JSON.parse() , jQuery.parseJSON() , etc.
Is there any significant difference when using each of these methods?
JSONcomes, then in the first caseajaxwill cause anerror, and in the second casesuccess- Dmitry Chistik