index.js
function describeFailure(ex) {
  return ex.stack?        ['  ---'
                          ,'    type: ' + ex.name
                          ,'    message: >'
                          ,       pad(6, ex.message)
                          ,'    stack: | '
                          ,       pad(6, ex.stack)
                          ,'  ...'
                          ].join('\n')
  :      /* otherwise */  ['  ---'
                          ,'    message: >'
                          ,       pad(6, ex.toString())
                          ,'  ...'
                          ].join('\n')
}
function describeFailure(ex) {
  return ex.stack?        ['  ---'
                          ,'    type: ' + ex.name
                          ,'    message: >'
                          ,       pad(6, ex.message)
                          ,'    stack: | '
                          ,       pad(6, ex.stack)
                          ,'  ...'
                          ].join('\n')
  :      /* otherwise */  ['  ---'
                          ,'    message: >'
                          ,       pad(6, ex.toString())
                          ,'  ...'
                          ].join('\n')
}
function describeFailure ( ex ) { return ex . stack ? [ '  ---' , '    type: ' + ex . name , '    message: >' , pad ( 6 , ex . message ) , '    stack: | ' , pad ( 6 , ex . stack ) , '  ...' ] . join ( '\n' ) : /* otherwise */ [ '  ---' , '    message: >' , pad ( 6 , ex . toString ( ) ) , '  ...' ] . join ( '\n' ) }
Returns a YAML serialisation of an exception.

@summary Error → String
Returns a YAML serialisation of an exception .