src/turndown.js
/**
 * Converts an element node to its Markdown equivalent
 * @private
 * @param {HTMLElement} node The node to convert
 * @returns A Markdown representation of the node
 * @type String
 */
Converts an element node to its Markdown equivalent
@private
@param {HTMLElement} node The node to convert
@returns A Markdown representation of the node
@type String
Converts an element node to its Markdown equivalent @private @param { HTMLElement } node The node to convert @returns A Markdown representation of the node @type String
async function replacementForNode (node) {
  var rule = this.rules.forNode(node)
  var content = process.call(this, node)
  var whitespace = node.flankingWhitespace
  if (whitespace.leading || whitespace.trailing) content = content.trim()
  var resplacement = await rule.replacement(content, node, this.options)
  return (
    whitespace.leading +
    resplacement +
    whitespace.trailing
  )
}
async function replacementForNode ( node ) { var rule = this . rules . forNode ( node ) var content = process . call ( this , node ) var whitespace = node . flankingWhitespace if ( whitespace . leading || whitespace . trailing ) content = content . trim ( ) var resplacement = await rule . replacement ( content , node , this . options ) return ( whitespace . leading + resplacement + whitespace . trailing ) }
Converts an element node to its Markdown equivalent
 @private
 @param {HTMLElement} node The node to convert
 @returns A Markdown representation of the node
 @type String
Converts an element node to its Markdown equivalent @private @param { HTMLElement } node The node to convert @returns A Markdown representation of the node @type String