Cleanup Codebase
The following discussion from !2403 (merged) should be addressed:
-
@wvffle started a discussion: (+1 comment) This vue update enables us to clean up the codebase.
According to https://blog.vuejs.org/posts/vue-3-3:
-
we can now safely use the imported types in props. We already have the TODOs for that, so I'd do it either in this MR or create an issue for it#2130 - we can now create generic components (I'd suggest doing it in &10): for lists: ui#17
<script setup lang="ts" generic="T extends string | number, U extends Item"> import type { Item } from './types' defineProps<{ id: T list: U[] }>() </script>
-
we can now write emit definitions (#2132Events
type in our code) in much more cleaner way -
we can now type slots. We should do it in vui before we start switching to it(https://dev.funkwhale.audio/funkwhale/vui/-/issues/24) -
we can replace the duplicatedhttps://dev.funkwhale.audio/funkwhale/vui/-/issues/25 and #2131<script>
tags withdefineOptions
(we may use it in frontend and we definately use it in vui)
-