options.json 3.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. {
  2. "type": "object",
  3. "additionalProperties": true,
  4. "properties": {
  5. "context": {
  6. "description": "A string indicating the root of your files.",
  7. "type": "string"
  8. },
  9. "emitError": {
  10. "description": "The errors found will always be emitted, to disable set to `false`.",
  11. "type": "boolean"
  12. },
  13. "emitWarning": {
  14. "description": "The warnings found will always be emitted, to disable set to `false`.",
  15. "type": "boolean"
  16. },
  17. "eslintPath": {
  18. "description": "Path to `eslint` instance that will be used for linting. If the `eslintPath` is a folder like a official eslint, or specify a `formatter` option. now you dont have to install `eslint`.",
  19. "type": "string"
  20. },
  21. "exclude": {
  22. "description": "Specify the files and/or directories to exclude. Must be relative to `options.context`.",
  23. "anyOf": [{ "type": "string" }, { "type": "array" }]
  24. },
  25. "resourceQueryExclude": {
  26. "description": "Specify the resource query to exclude.",
  27. "anyOf": [{ "instanceof": "RegExp" }, { "type": "array" }]
  28. },
  29. "failOnError": {
  30. "description": "Will cause the module build to fail if there are any errors, to disable set to `false`.",
  31. "type": "boolean"
  32. },
  33. "failOnWarning": {
  34. "description": "Will cause the module build to fail if there are any warnings, if set to `true`.",
  35. "type": "boolean"
  36. },
  37. "files": {
  38. "description": "Specify the files and/or directories to traverse. Must be relative to `options.context`.",
  39. "anyOf": [{ "type": "string" }, { "type": "array" }]
  40. },
  41. "extensions": {
  42. "description": "Specify extensions that should be checked.",
  43. "anyOf": [{ "type": "string" }, { "type": "array" }]
  44. },
  45. "fix": {
  46. "description": "Will enable ESLint autofix feature",
  47. "type": "boolean"
  48. },
  49. "formatter": {
  50. "description": "Accepts a function that will have one argument: an array of eslint messages (object). The function must return the output as a string.",
  51. "anyOf": [{ "type": "string" }, { "instanceof": "Function" }]
  52. },
  53. "lintDirtyModulesOnly": {
  54. "description": "Lint only changed files, skip lint on start.",
  55. "type": "boolean"
  56. },
  57. "quiet": {
  58. "description": "Will process and report errors only and ignore warnings, if set to `true`.",
  59. "type": "boolean"
  60. },
  61. "outputReport": {
  62. "description": "Write the output of the errors to a file, for example a checkstyle xml file for use for reporting on Jenkins CI",
  63. "anyOf": [
  64. {
  65. "type": "boolean"
  66. },
  67. {
  68. "type": "object",
  69. "additionalProperties": false,
  70. "properties": {
  71. "filePath": {
  72. "description": "The `filePath` is relative to the webpack config: output.path",
  73. "anyOf": [{ "type": "string" }]
  74. },
  75. "formatter": {
  76. "description": "You can pass in a different formatter for the output file, if none is passed in the default/configured formatter will be used",
  77. "anyOf": [{ "type": "string" }, { "instanceof": "Function" }]
  78. }
  79. }
  80. }
  81. ]
  82. },
  83. "threads": {
  84. "description": "Default is false. Set to true for an auto-selected pool size based on number of cpus. Set to a number greater than 1 to set an explicit pool size. Set to false, 1, or less to disable and only run in main process.",
  85. "anyOf": [{ "type": "number" }, { "type": "boolean" }]
  86. }
  87. }
  88. }