src/lib/cli.js
function printUserUnused() {
  if (!argv.unused) {
    return;
  }

  const userUnconfigured = _.difference(rules.stylelintNoDeprecated, rules.userRulesNames);
  let heading;

  if (!userUnconfigured.length) {
    heading = chalk.green('All rules are up-to-date!');
    printColumns(heading);

    return;
  }

  const rulesToPrint = _.map(userUnconfigured, rule => {
    return {
      rule,
      url: chalk.cyan(`https://stylelint.io/user-guide/rules/${rule}/`)
    };
  });

  heading = chalk.blue.underline('UNUSED: Available rules that are not configured:');

  printColumns(heading, rulesToPrint);
}
function printUserUnused() {
  if (!argv.unused) {
    return;
  }

  const userUnconfigured = _.difference(rules.stylelintNoDeprecated, rules.userRulesNames);
  let heading;

  if (!userUnconfigured.length) {
    heading = chalk.green('All rules are up-to-date!');
    printColumns(heading);

    return;
  }

  const rulesToPrint = _.map(userUnconfigured, rule => {
    return {
      rule,
      url: chalk.cyan(`https://stylelint.io/user-guide/rules/${rule}/`)
    };
  });

  heading = chalk.blue.underline('UNUSED: Available rules that are not configured:');

  printColumns(heading, rulesToPrint);
}
function printUserUnused ( ) { if ( ! argv . unused ) { return ; } const userUnconfigured = _ . difference ( rules . stylelintNoDeprecated , rules . userRulesNames ) ; let heading ; if ( ! userUnconfigured . length ) { heading = chalk . green ( 'All rules are up-to-date!' ) ; printColumns ( heading ) ; return ; } const rulesToPrint = _ . map ( userUnconfigured , rule => { return { rule , url : chalk . cyan ( ` ${ rule } ` ) } ; } ) ; heading = chalk . blue . underline ( 'UNUSED: Available rules that are not configured:' ) ; printColumns ( heading , rulesToPrint ) ; }
Print available stylelint rules that the user hasn't configured yet
Print available stylelint rules that the user hasn t configured yet