3 ms·
This is mainly for consistency with the previous JSON libraries developed by Douglas Crockford. In JavaScript, it's easy enough to "create your own API" by just
by shantanubala 15y ago
This is mainly for consistency with the previous JSON libraries developed by Douglas Crockford. In JavaScript, it's easy enough to "create your own API" by just aliasing JSON.stringify to JSON.serialize or even a local "serialize" function that it isn't too much of an issue.
As much as I agree that the naming convention isn't great, it's better to have consistency -- especially in a language as dynamic as JavaScript.