Browse Source

feat(nc-gui): Added types for metasWithIdAsKey in useMetas

pull/3612/head
Muhammed Mustafa 2 years ago
parent
commit
3679100c4d
  1. 2
      packages/nc-gui/composables/useMetas.ts

2
packages/nc-gui/composables/useMetas.ts

@ -11,7 +11,7 @@ export function useMetas() {
const metas = useState<{ [idOrTitle: string]: TableType | any }>('metas', () => ({})) const metas = useState<{ [idOrTitle: string]: TableType | any }>('metas', () => ({}))
const metasWithIdAsKey = computed(() => { const metasWithIdAsKey = computed<Record<string, TableType>>(() => {
const idEntries = Object.entries(metas.value).filter(([k, v]) => k === v.id) const idEntries = Object.entries(metas.value).filter(([k, v]) => k === v.id)
return Object.fromEntries(idEntries) return Object.fromEntries(idEntries)
}) })

Loading…
Cancel
Save