mirror of
https://github.com/go-gitea/gitea
synced 2024-12-22 08:54:23 +01:00
Update JS dependencies, adjust eslint config (#17904)
- Update all JS dependencies to latest versions - Add new lint rules, enable es2022 eslint parser features - Disable github/no-then, I feel the rule was too restricting
This commit is contained in:
parent
c7c723c548
commit
f7094c8161
9 changed files with 1490 additions and 1252 deletions
|
@ -6,7 +6,7 @@ ignorePatterns:
|
|||
|
||||
parserOptions:
|
||||
sourceType: module
|
||||
ecmaVersion: 2021
|
||||
ecmaVersion: latest
|
||||
|
||||
plugins:
|
||||
- eslint-plugin-unicorn
|
||||
|
@ -109,7 +109,7 @@ rules:
|
|||
github/no-implicit-buggy-globals: [0]
|
||||
github/no-inner-html: [0]
|
||||
github/no-innerText: [2]
|
||||
github/no-then: [2]
|
||||
github/no-then: [0]
|
||||
github/no-useless-passive: [2]
|
||||
github/prefer-observers: [0]
|
||||
github/require-passive-events: [2]
|
||||
|
@ -384,6 +384,7 @@ rules:
|
|||
unicorn/no-array-instanceof: [0]
|
||||
unicorn/no-array-method-this-argument: [2]
|
||||
unicorn/no-array-push-push: [2]
|
||||
unicorn/no-await-expression-member: [0]
|
||||
unicorn/no-console-spaces: [0]
|
||||
unicorn/no-document-cookie: [2]
|
||||
unicorn/no-empty-file: [2]
|
||||
|
@ -419,6 +420,7 @@ rules:
|
|||
unicorn/prefer-array-index-of: [2]
|
||||
unicorn/prefer-array-some: [2]
|
||||
unicorn/prefer-at: [0]
|
||||
unicorn/prefer-code-point: [2]
|
||||
unicorn/prefer-dataset: [2]
|
||||
unicorn/prefer-date-now: [2]
|
||||
unicorn/prefer-default-parameters: [0]
|
||||
|
|
|
@ -80,5 +80,5 @@ async function main() {
|
|||
]);
|
||||
}
|
||||
|
||||
main().then(exit).catch(exit); // eslint-disable-line github/no-then
|
||||
main().then(exit).catch(exit);
|
||||
|
||||
|
|
|
@ -54,5 +54,5 @@ async function main() {
|
|||
]);
|
||||
}
|
||||
|
||||
main().then(exit).catch(exit); // eslint-disable-line github/no-then
|
||||
main().then(exit).catch(exit);
|
||||
|
||||
|
|
2689
package-lock.json
generated
2689
package-lock.json
generated
File diff suppressed because it is too large
Load diff
32
package.json
32
package.json
|
@ -6,12 +6,12 @@
|
|||
"node": ">= 12.17.0"
|
||||
},
|
||||
"dependencies": {
|
||||
"@claviska/jquery-minicolors": "2.3.5",
|
||||
"@claviska/jquery-minicolors": "2.3.6",
|
||||
"@primer/octicons": "16.1.1",
|
||||
"add-asset-webpack-plugin": "2.0.1",
|
||||
"codemirror": "5.63.3",
|
||||
"codemirror": "5.64.0",
|
||||
"css-loader": "6.5.1",
|
||||
"dropzone": "6.0.0-beta.1",
|
||||
"dropzone": "6.0.0-beta.2",
|
||||
"easymde": "2.15.0",
|
||||
"esbuild-loader": "2.16.0",
|
||||
"escape-goat": "4.0.0",
|
||||
|
@ -22,40 +22,40 @@
|
|||
"less": "4.1.2",
|
||||
"less-loader": "10.2.0",
|
||||
"license-checker-webpack-plugin": "0.2.1",
|
||||
"mermaid": "8.13.3",
|
||||
"mini-css-extract-plugin": "2.4.4",
|
||||
"mermaid": "8.13.4",
|
||||
"mini-css-extract-plugin": "2.4.5",
|
||||
"monaco-editor": "0.30.1",
|
||||
"monaco-editor-webpack-plugin": "6.0.0",
|
||||
"pretty-ms": "7.0.1",
|
||||
"sortablejs": "1.14.0",
|
||||
"swagger-ui-dist": "4.1.0",
|
||||
"swagger-ui-dist": "4.1.2",
|
||||
"tributejs": "5.1.3",
|
||||
"vue": "2.6.14",
|
||||
"vue-bar-graph": "1.3.0",
|
||||
"vue-calendar-heatmap": "0.8.4",
|
||||
"vue-loader": "15.9.8",
|
||||
"vue-template-compiler": "2.6.14",
|
||||
"webpack": "5.63.0",
|
||||
"webpack": "5.64.4",
|
||||
"webpack-cli": "4.9.1",
|
||||
"workbox-routing": "6.3.0",
|
||||
"workbox-strategies": "6.3.0",
|
||||
"workbox-routing": "6.4.2",
|
||||
"workbox-strategies": "6.4.2",
|
||||
"worker-loader": "3.0.8",
|
||||
"wrap-ansi": "8.0.1"
|
||||
},
|
||||
"devDependencies": {
|
||||
"editorconfig-checker": "4.0.2",
|
||||
"eslint": "8.2.0",
|
||||
"eslint": "8.3.0",
|
||||
"eslint-plugin-github": "4.3.5",
|
||||
"eslint-plugin-html": "6.2.0",
|
||||
"eslint-plugin-import": "2.25.3",
|
||||
"eslint-plugin-unicorn": "38.0.1",
|
||||
"eslint-plugin-vue": "8.0.3",
|
||||
"jest": "27.3.1",
|
||||
"jest-extended": "1.1.0",
|
||||
"eslint-plugin-unicorn": "39.0.0",
|
||||
"eslint-plugin-vue": "8.1.1",
|
||||
"jest": "27.4.3",
|
||||
"jest-extended": "1.2.0",
|
||||
"jest-raw-loader": "1.0.1",
|
||||
"postcss-less": "5.0.0",
|
||||
"stylelint": "14.0.1",
|
||||
"stylelint-config-standard": "23.0.0",
|
||||
"stylelint": "14.1.0",
|
||||
"stylelint-config-standard": "24.0.0",
|
||||
"svgo": "2.8.0",
|
||||
"updates": "12.2.2"
|
||||
},
|
||||
|
|
|
@ -28,7 +28,7 @@ export function initCommonIssue() {
|
|||
action,
|
||||
issueIDs,
|
||||
elementId
|
||||
).then(() => { // eslint-disable-line github/no-then
|
||||
).then(() => {
|
||||
// NOTICE: This reset of checkbox state targets Firefox caching behaviour, as the
|
||||
// checkboxes stay checked after reload
|
||||
if (action === 'close' || action === 'open') {
|
||||
|
|
|
@ -361,7 +361,7 @@ export function initRepoIssueComments() {
|
|||
isChecked ? 'detach' : 'attach',
|
||||
issueId,
|
||||
id,
|
||||
).then(() => window.location.reload()); // eslint-disable-line github/no-then
|
||||
).then(() => window.location.reload());
|
||||
});
|
||||
|
||||
$('.dismiss-review-btn').on('click', function (e) {
|
||||
|
|
|
@ -162,7 +162,7 @@ export function initRepoCommentForm() {
|
|||
'clear',
|
||||
$listMenu.data('issue-id'),
|
||||
'',
|
||||
).then(() => window.location.reload()); // eslint-disable-line github/no-then
|
||||
).then(() => window.location.reload());
|
||||
}
|
||||
|
||||
$(this).parent().find('.item').each(function () {
|
||||
|
@ -205,7 +205,7 @@ export function initRepoCommentForm() {
|
|||
'',
|
||||
$menu.data('issue-id'),
|
||||
$(this).data('id'),
|
||||
).then(() => window.location.reload()); // eslint-disable-line github/no-then
|
||||
).then(() => window.location.reload());
|
||||
}
|
||||
|
||||
let icon = '';
|
||||
|
@ -238,7 +238,7 @@ export function initRepoCommentForm() {
|
|||
'',
|
||||
$menu.data('issue-id'),
|
||||
$(this).data('id'),
|
||||
).then(() => window.location.reload()); // eslint-disable-line github/no-then
|
||||
).then(() => window.location.reload());
|
||||
}
|
||||
|
||||
$list.find('.selected').html('');
|
||||
|
|
|
@ -1,4 +1,3 @@
|
|||
/* eslint-disable github/no-then */
|
||||
const {appSubUrl, csrfToken} = window.config;
|
||||
|
||||
export function initUserAuthU2fAuth() {
|
||||
|
|
Loading…
Reference in a new issue