1
0
mirror of https://github.com/teoxoy/factorio-blueprint-editor.git synced 2024-11-21 17:06:30 +02:00
factorio-blueprint-editor/.eslint.base.yml
2020-05-30 21:07:27 +08:00

55 lines
1.5 KiB
YAML

rules:
# Best Practices (https://eslint.org/docs/rules/#best-practices)
curly: [warn, all]
dot-notation: [error, allowPattern: '^[a-z]+(_[a-z]+)+$']
eqeqeq: [warn, always]
guard-for-in: error
no-new-func: error
no-new-wrappers: error
no-param-reassign: error
no-return-assign: [warn, always]
no-return-await: error
no-self-compare: error
no-sequences: error
no-throw-literal: error
no-unmodified-loop-condition: error
no-unused-expressions: error
no-useless-concat: error
no-useless-return: error
no-void: error
no-with: error
wrap-iife: [error, inside]
yoda: [error, never, exceptRange: true]
# Stylistic Issues (https://eslint.org/docs/rules/#stylistic-issues)
func-style: [error, declaration, allowArrowFunctions: true]
no-mixed-operators:
- error
- groups:
- ['&', '|', '^', '~', '<<', '>>', '>>>']
- ['==', '!=', '===', '!==', '>', '>=', '<', '<=']
- ['&&', '||']
- [in, instanceof]
allowSamePrecedence: true
no-multi-assign: error
no-negated-condition: error
no-new-object: error
no-plusplus: [error, allowForLoopAfterthoughts: true]
no-unneeded-ternary: error
operator-assignment: [error, always]
prefer-object-spread: error
spaced-comment:
- warn
- always
- block:
balanced: true
# ECMAScript 6 (https://eslint.org/docs/rules/#ecmascript-6)
arrow-body-style: [error, as-needed]
no-confusing-arrow: [error, allowParens: true]
no-var: error
prefer-const: error
prefer-rest-params: error
prefer-spread: error
prefer-template: error