Ohm-Management - Projektarbeit B-ME
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

eslint-all.js 966B

12345678910111213141516171819202122232425262728293031
  1. /**
  2. * @fileoverview Config to enable all rules.
  3. * @author Robert Fletcher
  4. */
  5. "use strict";
  6. //------------------------------------------------------------------------------
  7. // Requirements
  8. //------------------------------------------------------------------------------
  9. const load = require("../lib/load-rules"),
  10. Rules = require("../lib/rules");
  11. const rules = new Rules();
  12. //------------------------------------------------------------------------------
  13. // Helpers
  14. //------------------------------------------------------------------------------
  15. const enabledRules = Object.keys(load()).reduce((result, ruleId) => {
  16. if (!rules.get(ruleId).meta.deprecated) {
  17. result[ruleId] = "error";
  18. }
  19. return result;
  20. }, {});
  21. //------------------------------------------------------------------------------
  22. // Public Interface
  23. //------------------------------------------------------------------------------
  24. module.exports = { rules: enabledRules };