code: function _parse(loc, type, data, callback) {
    // explicit type
    if(type && type !== 'auto') {
      return _typedParse(loc, type, data, callback);
    }
    // typed via text-like extension
    if(loc && (endsWith(loc, '.txt'))) {
      return _typedParse(loc, 'text', data, callback);
    }
    // typed via JSON-like extension
    if(loc && (endsWith(loc, '.json') ||
      endsWith(loc, '.jsonld') ||
      endsWith(loc, '.json-ld'))) {
      return _typedParse(loc, 'json', data, callback);
    }
    // typed via HTML-like extension
    if(loc && (endsWith(loc, '.xml') ||
      endsWith(loc, '.html') ||
      endsWith(loc, '.xhtml'))) {
      return _typedParse(loc, 'html', data, callback);
    }
    // try ~JSON
    _typedParse(loc, 'application/ld+json', data, function(err, data) {
      if(err) {
        // try ~HTML
        return _typedParse(loc, 'text/html', data, function(err, data) {
          if(err) {
            return callback({
              message: 'Unable to auto-detect format.',
              url: loc
            });
          }
          callback(null, data);
        });
      }
      callback(null, data);
    });
  }
docs: Parse data.
  
  @param loc location the data came from
  @param type content type of the string or null to attempt to auto-detect
  @param data the data string or buffer
  @param callback function(err, data) called with errors and result data