We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent aa3d413 commit fcbb687Copy full SHA for fcbb687
packages/runtime/src/components/Checker.ce.vue
@@ -5,11 +5,19 @@ defineProps<{
5
diagnostics?: any[]
6
base: string
7
}>()
8
+
9
+const key = (diagnostic: any): string => {
10
+ if (diagnostic.loc) {
11
+ return `${diagnostic.loc.file}-${diagnostic.loc.line}-${diagnostic.loc.column}`;
12
+ } else {
13
+ return diagnostic.id;
14
+ }
15
+}
16
</script>
17
18
<template>
19
<ul>
- <Diagnostic v-for="d in diagnostics" :diagnostic="d" :base="base" />
20
+ <Diagnostic v-for="d in diagnostics" :diagnostic="d" :base="base" :key="key(d)" />
21
</ul>
22
</template>
23
0 commit comments