code: function unpack(imValue) {
      var value;
      var valueType = Object.prototype.toString.call(imValue).slice(8, -1);
      switch (valueType) {
          case 'String':
              value = imValue + '';
              break;
          case 'Number':
              value = imValue + 0;
              break;
          case 'Boolean':
              value = imValue == true;
              break;
          case 'Array':
              value = imValue.map(function (ele) { return unpack(ele); });
              break;
          case 'Object':
              value = {};
              for (var key in imValue) {
                  if (imValue.hasOwnProperty(key)) {
                      value[key] = unpack(imValue[key]);
                  }
              }
              break;
          default: value = imValue;
      }
      return value;
  }
docs: pastate imState 对象拆包
  @param imValue