summaryrefslogtreecommitdiffstats
path: root/web_src/js/index.js
diff options
context:
space:
mode:
authorsilverwind <me@silverwind.io>2023-04-02 00:40:22 +0200
committerGitHub <noreply@github.com>2023-04-01 18:40:22 -0400
commitae361135681477db0dbeb5b42078efe77b4dd5e4 (patch)
treef482204f2a0c46e76767ea235c4e65b2f9f749a5 /web_src/js/index.js
parenteadda68ded10fe65a6351198b47163eba9762d7a (diff)
downloadgitea-ae361135681477db0dbeb5b42078efe77b4dd5e4.tar.gz
gitea-ae361135681477db0dbeb5b42078efe77b4dd5e4.zip
Remove jQuery ready usage (#23858)
Replace it with equal function of our own and enable the eslint rule to forbid future usage.
Diffstat (limited to 'web_src/js/index.js')
-rw-r--r--web_src/js/index.js4
1 files changed, 2 insertions, 2 deletions
diff --git a/web_src/js/index.js b/web_src/js/index.js
index 80edc05480..839289e9d2 100644
--- a/web_src/js/index.js
+++ b/web_src/js/index.js
@@ -1,7 +1,6 @@
// bootstrap module must be the first one to be imported, it handles webpack lazy-loading and global errors
import './bootstrap.js';
-import $ from 'jquery';
import {initRepoActivityTopAuthorsChart} from './components/RepoActivityTopAuthors.vue';
import {initDashboardRepoList} from './components/DashboardRepoList.vue';
@@ -90,6 +89,7 @@ import {initCaptcha} from './features/captcha.js';
import {initRepositoryActionView} from './components/RepoActionView.vue';
import {initGlobalTooltips} from './modules/tippy.js';
import {initGiteaFomantic} from './modules/fomantic.js';
+import {onDomReady} from './utils/dom.js';
// Run time-critical code as soon as possible. This is safe to do because this
// script appears at the end of <body> and rendered HTML is accessible at that point.
@@ -98,7 +98,7 @@ initFormattingReplacements();
// Init Gitea's Fomantic settings
initGiteaFomantic();
-$(document).ready(() => {
+onDomReady(() => {
initGlobalCommon();
initGlobalTooltips();