How to use the jshint/src/cli.extract function in jshint

To help you get started, we’ve selected a few jshint 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 spalger / gulp-jshint / src / extract.js View on Github external
fileIgnored(file, function (err, ignored) {
      if (err) return cb(err);
      if (ignored) return cb(null, file);

      file.jshint = file.jshint || {};
      file.jshint.extracted = jshintcli.extract(file.contents.toString('utf8'), when);
      return cb(null, file);
    });
  });
github danawoodman / starter / node_modules / gulp-jshint / src / extract.js View on Github external
fileIgnored(file, function (err, ignored) {
      if (err) return cb(err);
      if (ignored) return cb(null, file);

      file.jshint = file.jshint || {};
      file.jshint.extracted = jshintcli.extract(file.contents.toString('utf8'), when);
      return cb(null, file);
    });
  });