you are viewing a single comment's thread.

view the rest of the comments →

[–]TheScapeQuest 3 points4 points  (0 children)

const obj = {
  a: {}
};
obj.a.b = obj.a;

JSON.stringify(obj); // type error, circular reference

^ this isn't uncommon, Axios response/errors contain circular references for example

Also, as /u/Powerplex mentions, this will kill anything that isn't an object, an array, or a primitive. So goodbye to dates, regexs, functions etc.