function(deep) {
      var newObj = {},
          i;

      if (obj === null || !wysihtml5.lang.object(obj).isPlainObject()) {
        return obj;
      }

      for (i in obj) {
        if(obj.hasOwnProperty(i)) {
          if (deep) {
            newObj[i] = wysihtml5.lang.object(obj[i]).clone(deep);
          } else {
            newObj[i] = obj[i];
          }
        }
      }
      return newObj;
    }
function(deep) {
      var newObj = {},
          i;

      if (obj === null || !wysihtml5.lang.object(obj).isPlainObject()) {
        return obj;
      }

      for (i in obj) {
        if(obj.hasOwnProperty(i)) {
          if (deep) {
            newObj[i] = wysihtml5.lang.object(obj[i]).clone(deep);
          } else {
            newObj[i] = obj[i];
          }
        }
      }
      return newObj;
    }
function ( deep ) { var newObj = { } , i ; if ( obj === null || ! wysihtml5 . lang . object ( obj ) . isPlainObject ( ) ) { return obj ; } for ( i in obj ) { if ( obj . hasOwnProperty ( i ) ) { if ( deep ) { newObj [ i ] = wysihtml5 . lang . object ( obj [ i ] ) . clone ( deep ) ; } else { newObj [ i ] = obj [ i ] ; } } } return newObj ; }
@example
wysihtml5.lang.object({ foo: 1 }).clone();
// => { foo: 1 }

v0.4.14 adds options for deep clone : wysihtml5.lang.object({ foo: 1 }).clone(true);
@example wysihtml5 . lang . object ( { foo : 1 } ) . clone () ; // = > { foo : 1 }
Clone the object