mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-29 10:57:44 +09:00 
			
		
		
		
	Tweak eslint config, fix new issues (#35019)
1. Enable [`@typescript-eslint/no-unnecessary-type-conversion`](https://typescript-eslint.io/rules/no-unnecessary-type-conversion/), I think the two cases that were hit are safe cases. 2. Disable `no-new-func`, `@typescript-eslint/no-implied-eval` does the same but better.
This commit is contained in:
		| @@ -44,7 +44,7 @@ type ToastifyElement = HTMLElement & {_giteaToastifyInstance?: Toast }; | ||||
|  | ||||
| // See https://github.com/apvarun/toastify-js#api for options | ||||
| function showToast(message: string, level: Intent, {gravity, position, duration, useHtmlBody, preventDuplicates = true, ...other}: ToastOpts = {}): Toast { | ||||
|   const body = useHtmlBody ? String(message) : htmlEscape(message); | ||||
|   const body = useHtmlBody ? message : htmlEscape(message); | ||||
|   const parent = document.querySelector('.ui.dimmer.active') ?? document.body; | ||||
|   const duplicateKey = preventDuplicates ? (preventDuplicates === true ? `${level}-${body}` : preventDuplicates) : ''; | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user