index.js
function stringify(x) {
	if (x === Object(x) && x.t === 'MetaString') return x.c;

  var result = [];
  var go = function (key, val) {
    if (key === 'Str') result.push(val);
    else if (key === 'Code') result.push(val[1]);
    else if (key === 'Math') result.push(val[1]);
    else if (key === 'LineBreak') result.push(' ');
    else if (key === 'Space') result.push(' ');
  };
  walk(x, go, '', {});
  return result.join('');
}
function stringify(x) {
	if (x === Object(x) && x.t === 'MetaString') return x.c;

  var result = [];
  var go = function (key, val) {
    if (key === 'Str') result.push(val);
    else if (key === 'Code') result.push(val[1]);
    else if (key === 'Math') result.push(val[1]);
    else if (key === 'LineBreak') result.push(' ');
    else if (key === 'Space') result.push(' ');
  };
  walk(x, go, '', {});
  return result.join('');
}
function stringify ( x ) { if ( x === Object ( x ) && x . t === 'MetaString' ) return x . c ; var result = [ ] ; var go = function ( key , val ) { if ( key === 'Str' ) result . push ( val ) ; else if ( key === 'Code' ) result . push ( val [ 1 ] ) ; else if ( key === 'Math' ) result . push ( val [ 1 ] ) ; else if ( key === 'LineBreak' ) result . push ( ' ' ) ; else if ( key === 'Space' ) result . push ( ' ' ) ; } ; walk ( x , go , '' , { } ) ; return result . join ( '' ) ; }
Walks the tree x and returns concatenated string content, leaving out all
formatting.
@param  {Object} x The object to walk
@return {String}   JSON string
Walks the tree x and returns concatenated string content leaving out all formatting .