client/shim.js
function stringify(obj, replacer, spaces, cycleReplacer) {
      if (typeof replacer !== 'function') {
        replacer = null;
      }
      return JSON.stringify(obj, serializer(replacer, cycleReplacer), spaces);
    }
function stringify(obj, replacer, spaces, cycleReplacer) {
      if (typeof replacer !== 'function') {
        replacer = null;
      }
      return JSON.stringify(obj, serializer(replacer, cycleReplacer), spaces);
    }
stringify() and serizlier() from https://github.com/moll/json-stringify-safe