Top-Bar-Organizer/.eslintrc.yml
Julian Schacher cedb54ed64
Other: Disallow omitting curly braces and enforce one true brace style
Do this by updating the ESLint config accordingly and also fix new
complaints.
2023-01-28 23:34:15 +01:00

54 lines
890 B
YAML

env:
es2021: true
extends: 'eslint:recommended'
parserOptions:
ecmaVersion: 2022
rules:
indent:
- error
- 4
- SwitchCase: 1
linebreak-style:
- error
- unix
quotes:
- error
- double
semi:
- error
- always
no-unused-vars:
- error
- argsIgnorePattern: "^_"
curly:
- error
- all
brace-style:
- error
- 1tbs
# Rules from GJS Style Guide regarding whitespace.
# See here: https://gjs.guide/guides/gjs/style-guide.html#whitespace
func-call-spacing:
- error
- never
array-bracket-spacing:
- error
- never
space-before-function-paren:
- error
- never
space-before-blocks:
- error
- always
key-spacing:
- error
- beforeColon: false
afterColon: true
mode: strict
object-curly-spacing:
- error
- always
globals:
imports: readonly
log: readonly