.jshintrc 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. {
  2. "bitwise": false, // Prohibit bitwise operators (&, |, ^, etc.).
  3. "browser": true, // Standard browser globals e.g. `window`, `document`.
  4. "camelcase": false, // Permit only camelcase for `var` and `object indexes`.
  5. "curly": true, // Require {} for every new block or scope.
  6. "devel": false, // Allow development statements e.g. `console.log();`.
  7. "eqeqeq": true, // Require triple equals i.e. `===`.
  8. "esnext": true, // Allow ES.next specific features such as `const` and `let`.
  9. "freeze": true, // Forbid overwriting prototypes of native objects such as Array, Date and so on.
  10. "immed": true, // Require immediate invocations to be wrapped in parens e.g. `( function(){}() );`
  11. "indent": 2, // Specify indentation spacing
  12. "latedef": true, // Prohibit variable use before definition.
  13. "newcap": false, // Require capitalization of all constructor functions e.g. `new F()`.
  14. "noarg": true, // Prohibit use of `arguments.caller` and `arguments.callee`.
  15. "node": true, // Enable globals available when code is running inside of the NodeJS runtime environment.
  16. "noempty": true, // Prohibit use of empty blocks.
  17. "nonew": true, // Prohibits the use of constructor functions for side-effects
  18. "quotmark": "single", // Define quotes to string values.
  19. "regexp": true, // Prohibit `.` and `[^...]` in regular expressions.
  20. "smarttabs": false, // Supress warnings about mixed tabs and spaces
  21. "strict": true, // Require `use strict` pragma in every file.
  22. "trailing": true, // Prohibit trailing whitespaces.
  23. "undef": true, // Require all non-global variables be declared before they are used.
  24. "unused": true, // Warn unused variables.
  25. "maxparams": 4, // Maximum number of parameters for a function
  26. "maxstatements": 15, // Maximum number of statements in a function
  27. "maxcomplexity": 10, // Cyclomatic complexity (http://en.wikipedia.org/wiki/Cyclomatic_complexity)
  28. "maxdepth": 4, // Maximum depth of nested control structures
  29. "maxlen": 120, // Maximum number of cols in a line
  30. "multistr": true, // Allow use of multiline EOL escaping
  31. "experimental": ["asyncawait", "asyncreqawait"],
  32. "predef": [ // Extra globals.
  33. "after",
  34. "afterEach",
  35. "before",
  36. "beforeEach",
  37. "define",
  38. "describe",
  39. "exports",
  40. "it",
  41. "web3",
  42. "artifacts",
  43. "contract",
  44. "assert"
  45. ]
  46. }