diff options
Diffstat (limited to '.eslintrc.js')
-rw-r--r-- | .eslintrc.js | 70 |
1 files changed, 34 insertions, 36 deletions
diff --git a/.eslintrc.js b/.eslintrc.js index 9e7ab34d..944cc869 100644 --- a/.eslintrc.js +++ b/.eslintrc.js @@ -1,3 +1,4 @@ +/* global module */ module.exports = { env: { browser: true, @@ -25,9 +26,14 @@ module.exports = { "linebreak-style": ["error", "unix"], "no-extra-semi": "error", "no-mixed-spaces-and-tabs": "error", + "no-multi-spaces": "error", + "no-redeclare": ["error", {builtinGlobals: false}], "no-trailing-spaces": "error", + "no-unused-vars": "off", "no-whitespace-before-property": "error", "object-curly-newline": ["error", {consistent: true, multiline: true}], + "object-curly-spacing": ["error", "never"], + "operator-linebreak": ["error", "after"], "quote-props": ["error", "consistent-as-needed"], "semi": ["error", "always"], "semi-spacing": "error", @@ -40,51 +46,43 @@ module.exports = { "switch-colon-spacing": "error", "template-curly-spacing": ["error", "never"], "unicode-bom": "error", - "no-multi-spaces": "error", - "object-curly-spacing": ["error", "never"], - "operator-linebreak": ["error", "after"], - "no-unused-vars": "off", - "no-redeclare": "off", }, globals: { - // this file - module: "writable", //script.js - gradioApp: "writable", - onUiLoaded: "writable", - onUiUpdate: "writable", - onOptionsChanged: "writable", + gradioApp: "readonly", + onUiLoaded: "readonly", + onUiUpdate: "readonly", + onOptionsChanged: "readonly", uiCurrentTab: "writable", - uiElementIsVisible: "writable", - uiElementInSight: "writable", - executeCallbacks: "writable", + uiElementIsVisible: "readonly", + uiElementInSight: "readonly", + executeCallbacks: "readonly", //ui.js opts: "writable", - all_gallery_buttons: "writable", - selected_gallery_button: "writable", - selected_gallery_index: "writable", - args_to_array: "writable", - switch_to_txt2img: "writable", - switch_to_img2img_tab: "writable", - switch_to_img2img: "writable", - switch_to_sketch: "writable", - switch_to_inpaint: "writable", - switch_to_inpaint_sketch: "writable", - switch_to_extras: "writable", - get_tab_index: "writable", - create_submit_args: "writable", - restart_reload: "writable", - updateInput: "writable", + all_gallery_buttons: "readonly", + selected_gallery_button: "readonly", + selected_gallery_index: "readonly", + switch_to_txt2img: "readonly", + switch_to_img2img_tab: "readonly", + switch_to_img2img: "readonly", + switch_to_sketch: "readonly", + switch_to_inpaint: "readonly", + switch_to_inpaint_sketch: "readonly", + switch_to_extras: "readonly", + get_tab_index: "readonly", + create_submit_args: "readonly", + restart_reload: "readonly", + updateInput: "readonly", //extraNetworks.js - requestGet: "writable", - popup: "writable", + requestGet: "readonly", + popup: "readonly", // from python - localization: "writable", + localization: "readonly", // progrssbar.js - randomId: "writable", - requestProgress: "writable", + randomId: "readonly", + requestProgress: "readonly", // imageviewer.js - modalPrevImage: "writable", - modalNextImage: "writable", + modalPrevImage: "readonly", + modalNextImage: "readonly", } }; |