var serialize = function (value) {
    try {
      return JSON.stringify(value);
    } catch (e) {
      if (window.console) {