mirror of
				https://github.com/go-gitea/gitea.git
				synced 2025-10-27 17:06:28 +01:00 
			
		
		
		
	Enable Typescript noImplicitAny (#33322)
				
					
				
			Enable `noImplicitAny` and fix all issues. --------- Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
This commit is contained in:
		| @@ -1,5 +1,5 @@ | ||||
| <script lang="ts" setup> | ||||
| import DiffFileTreeItem from './DiffFileTreeItem.vue'; | ||||
| import DiffFileTreeItem, {type Item} from './DiffFileTreeItem.vue'; | ||||
| import {loadMoreFiles} from '../features/repo-diff.ts'; | ||||
| import {toggleElem} from '../utils/dom.ts'; | ||||
| import {diffTreeStore} from '../modules/stores.ts'; | ||||
| @@ -11,7 +11,7 @@ const LOCAL_STORAGE_KEY = 'diff_file_tree_visible'; | ||||
| const store = diffTreeStore(); | ||||
|  | ||||
| const fileTree = computed(() => { | ||||
|   const result = []; | ||||
|   const result: Array<Item> = []; | ||||
|   for (const file of store.files) { | ||||
|     // Split file into directories | ||||
|     const splits = file.Name.split('/'); | ||||
| @@ -24,15 +24,10 @@ const fileTree = computed(() => { | ||||
|       if (index === splits.length) { | ||||
|         isFile = true; | ||||
|       } | ||||
|       let newParent = { | ||||
|       let newParent: Item = { | ||||
|         name: split, | ||||
|         children: [], | ||||
|         isFile, | ||||
|       } as { | ||||
|         name: string, | ||||
|         children: any[], | ||||
|         isFile: boolean, | ||||
|         file?: any, | ||||
|       }; | ||||
|  | ||||
|       if (isFile === true) { | ||||
|   | ||||
		Reference in New Issue
	
	Block a user