mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-31 21:28:11 +09:00 
			
		
		
		
	Remove jQuery ready usage (#23858)
Replace it with equal function of our own and enable the eslint rule to forbid future usage.
This commit is contained in:
		| @@ -67,3 +67,11 @@ export function hideElem(el) { | ||||
| export function toggleElem(el, force) { | ||||
|   elementsCall(el, toggleShown, force); | ||||
| } | ||||
|  | ||||
| export function onDomReady(cb) { | ||||
|   if (document.readyState === 'loading') { | ||||
|     document.addEventListener('DOMContentLoaded', cb); | ||||
|   } else { | ||||
|     cb(); | ||||
|   } | ||||
| } | ||||
|   | ||||
		Reference in New Issue
	
	Block a user