0
0
Fork 0
mirror of https://github.com/go-gitea/gitea synced 2024-12-30 03:34:29 +01:00

Enable a few more eslint rules (#12145)

This gets the config closer to what 1.12 had.

Related: https://github.com/go-gitea/gitea/pull/12129
This commit is contained in:
silverwind 2020-07-05 12:51:29 +02:00 committed by GitHub
parent c6d6c51ada
commit 15d3aa7b95
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -31,6 +31,8 @@ overrides:
- files: ["web_src/**/*worker.js"] - files: ["web_src/**/*worker.js"]
env: env:
worker: true worker: true
rules:
no-restricted-globals: [2, addEventListener, blur, close, closed, confirm, defaultStatus, defaultstatus, error, event, external, find, focus, frameElement, frames, history, innerHeight, innerWidth, isFinite, isNaN, length, location, locationbar, menubar, moveBy, moveTo, name, onblur, onerror, onfocus, onload, onresize, onunload, open, opener, opera, outerHeight, outerWidth, pageXOffset, pageYOffset, parent, print, removeEventListener, resizeBy, resizeTo, screen, screenLeft, screenTop, screenX, screenY, scroll, scrollbars, scrollBy, scrollTo, scrollX, scrollY, status, statusbar, stop, toolbar, top]
rules: rules:
accessor-pairs: [2] accessor-pairs: [2]
@ -116,7 +118,7 @@ rules:
import/order: [0] import/order: [0]
import/prefer-default-export: [0] import/prefer-default-export: [0]
import/unambiguous: [0] import/unambiguous: [0]
indent: [2, 2, {ignoreComments: true, SwitchCase: 1}] indent: [2, 2, {SwitchCase: 1}]
init-declarations: [0] init-declarations: [0]
key-spacing: [2] key-spacing: [2]
keyword-spacing: [2] keyword-spacing: [2]
@ -165,7 +167,7 @@ rules:
no-dupe-keys: [2] no-dupe-keys: [2]
no-duplicate-case: [2] no-duplicate-case: [2]
no-duplicate-imports: [2] no-duplicate-imports: [2]
no-else-return: [0] no-else-return: [2]
no-empty-character-class: [2] no-empty-character-class: [2]
no-empty-function: [0] no-empty-function: [0]
no-empty-pattern: [2] no-empty-pattern: [2]
@ -223,7 +225,7 @@ rules:
no-redeclare: [2] no-redeclare: [2]
no-regex-spaces: [2] no-regex-spaces: [2]
no-restricted-exports: [0] no-restricted-exports: [0]
no-restricted-globals: [0] no-restricted-globals: [2, addEventListener, blur, close, closed, confirm, defaultStatus, defaultstatus, error, event, external, find, focus, frameElement, frames, history, innerHeight, innerWidth, isFinite, isNaN, length, location, locationbar, menubar, moveBy, moveTo, name, onblur, onerror, onfocus, onload, onresize, onunload, open, opener, opera, outerHeight, outerWidth, pageXOffset, pageYOffset, parent, print, removeEventListener, resizeBy, resizeTo, screen, screenLeft, screenTop, screenX, screenY, scroll, scrollbars, scrollBy, scrollTo, scrollX, scrollY, self, status, statusbar, stop, toolbar, top]
no-restricted-imports: [0] no-restricted-imports: [0]
no-restricted-syntax: [2, WithStatement, ForInStatement, LabeledStatement] no-restricted-syntax: [2, WithStatement, ForInStatement, LabeledStatement]
no-return-assign: [0] no-return-assign: [0]
@ -264,7 +266,7 @@ rules:
no-useless-constructor: [2] no-useless-constructor: [2]
no-useless-escape: [2] no-useless-escape: [2]
no-useless-rename: [2] no-useless-rename: [2]
no-useless-return: [0] no-useless-return: [2]
no-var: [2] no-var: [2]
no-void: [2] no-void: [2]
no-warning-comments: [0] no-warning-comments: [0]