src/reporters/ConsoleReporter.js
function formatLine({ rule, message, location }, metrics) {
  const { line, col } = location;
  const { line: lineW, col: colW, message: msgW } = metrics;
  const loc = sprintf(`%${lineW}d:%-${colW}d`, line, col);
  const msg = sprintf(`%-${msgW}s`, message);
  return `  ${loc}  ${msg}  ${rule}`;
}
function formatLine({ rule, message, location }, metrics) {
  const { line, col } = location;
  const { line: lineW, col: colW, message: msgW } = metrics;
  const loc = sprintf(`%${lineW}d:%-${colW}d`, line, col);
  const msg = sprintf(`%-${msgW}s`, message);
  return `  ${loc}  ${msg}  ${rule}`;
}
function formatLine ( { rule , message , location } , metrics ) { const { line , col } = location ; const { line : lineW , col : colW , message : msgW } = metrics ; const loc = sprintf ( ` ${ lineW } ${ colW } ` , line , col ) ; const msg = sprintf ( ` ${ msgW } ` , message ) ; return ` ${ loc } ${ msg } ${ rule } ` ; }
Formats the output line with the widths given in `metrics`

@private
@param {{
rule: string,
message: string,
location: parse5.LocationInfo
}} error
@param {{line: number, col: number, message: number}} metrics
@return {string}
Formats the output line with the widths given in metrics