How to use the htmlhint.default.defaultRuleset function in htmlhint

To help you get started, we’ve selected a few htmlhint examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github groupe-sii / sonar-web-frontend-reporters / lib / reporters / htmlhint.reporter.js View on Github external
launch (done) {
    let optionsRC = this.getRCFile(this.options.rulesFile);
    this.options.htmlhint = [];
    for (var key in HTMLHint.defaultRuleset) {
      if (HTMLHint.defaultRuleset.hasOwnProperty(key)) {
        this.options.htmlhint[key] = 1;
      }
    }

    for (var rule in optionsRC) {
      if (optionsRC[rule]) {
        this.options.htmlhint[rule] = optionsRC[rule];
      } else {
        delete this.options.htmlhint[rule];
      }
    }

    glob(this.options.src, (er, files) => {
      this.processFiles(files, this.options);
      this.closeReporter(this.options.report);
github groupe-sii / sonar-web-frontend-reporters / lib / reporters / htmlhint.reporter.js View on Github external
launch (done) {
    let optionsRC = this.getRCFile(this.options.rulesFile);
    this.options.htmlhint = [];
    for (var key in HTMLHint.defaultRuleset) {
      if (HTMLHint.defaultRuleset.hasOwnProperty(key)) {
        this.options.htmlhint[key] = 1;
      }
    }

    for (var rule in optionsRC) {
      if (optionsRC[rule]) {
        this.options.htmlhint[rule] = optionsRC[rule];
      } else {
        delete this.options.htmlhint[rule];
      }
    }

    glob(this.options.src, (er, files) => {
      this.processFiles(files, this.options);
      this.closeReporter(this.options.report);