diff --git a/content/2.defense-systems/abie.md b/content/2.defense-systems/abie.md index d24eab506197300838532a01a5b342877c76b642..a4e50c276f4a1d7896f6bf4ba9fb54a1f6ffb162 100644 --- a/content/2.defense-systems/abie.md +++ b/content/2.defense-systems/abie.md @@ -1,5 +1,8 @@ --- title: AbiE +tableDescription: + doi: 10.1093/nar/gkt1419 + other: blabla --- AbiE is a family of an anti-phage defense systems. They act through a Toxin-Antitoxin mechanism, and are comprised of a pair of genes, with one gene being toxic while the other confers immunity to this toxicity. diff --git a/pages/defense-systems.vue b/pages/defense-systems.vue new file mode 100644 index 0000000000000000000000000000000000000000..815354623bf11f717a0af65c73c525362360c7e9 --- /dev/null +++ b/pages/defense-systems.vue @@ -0,0 +1,18 @@ +<script setup lang="ts"> +const { data, error, pending } = await useAsyncData('list-defense-systems', () => queryContent('/defense-systems').find()) +const defaultHeaders = ref([{ title: 'System', key: "title" }]) +console.log(data.value) +const tableDescriptionKey = ref("tableDescription") +const headers = data.value ? ref(Array.from(data.value.reduce((headerSet, df) => { + if (df?.[tableDescriptionKey.value]) { + return new Set([...headerSet, ...Object.keys(df[tableDescriptionKey.value])]) + } + else { return headerSet } +}, new Set())).map(value => { return { title: value, key: value } }) + +) : defaultHeaders +console.log(headers.value) +</script> +<template> + <v-card :loading="pending"></v-card> +</template> \ No newline at end of file