mirror of
https://github.com/go-gitea/gitea.git
synced 2026-11-02 13:44:16 +09:00
refactor: improve types in the frontend, misc fixes (#39142)
This commit is contained in:
1 parent
535fc29ae8
commit
7c93ead628
46 files changed
+392
-217
No files matched your search
@@ -47,8 +47,8 @@ function processAssetsSvgFiles(pattern: string, opts: Opts = {}) {
|
||||
return glob(pattern).map((path) => processAssetsSvgFile(path, opts));
|
||||
}
|
||||
|
||||
function lowercaseKeys(obj: Record<string, any>) {
|
||||
return Object.fromEntries(Object.entries(obj).map(([key, value]) => [key.toLowerCase(), value]));
|
||||
function lowercaseKeys<T extends Record<string, unknown>>(obj: T): T {
|
||||
return Object.fromEntries(Object.entries(obj).map(([key, value]) => [key.toLowerCase(), value])) as T;
|
||||
}
|
||||
|
||||
async function processMaterialFileIcons() {
|
||||
|
||||
Reference in new issue
Block a user