node_modules/hydrolysis/lib/ast-utils/ast-value.js
/**
 * Make it look like an object
 */
Make it look like an object
Make it look like an object
function objectExpressionToValue(obj) {
  var value = '{';
  for (var i=0; i<obj.properties.length; i++) {
    var k = expressionToValue(obj.properties[i].key);
    var v = expressionToValue(obj.properties[i].value);
    if (v === undefined)
      continue;
    if (i !== 0)
      value += ', ';
    value += '"' + k + '": ' + v;
  }
  value += '}';
  return value;
}
function objectExpressionToValue ( obj ) { var value = '{' ; for ( var i = 0 ; i < obj . properties . length ; i ++ ) { var k = expressionToValue ( obj . properties [ i ] . key ) ; var v = expressionToValue ( obj . properties [ i ] . value ) ; if ( v === undefined ) continue ; if ( i !== 0 ) value += ', ' ; value += '"' + k + '": ' + v ; } value += '}' ; return value ; }
Make it look like an object
Make it look like an object