Browse Source

chore(gui-v2): add lint script & lint files

pull/2716/head
Braks 2 years ago committed by Pranav C
parent
commit
106c2c529a
  1. 18
      packages/nc-gui-v2/components/smartsheet/Grid.vue
  2. 3
      packages/nc-gui-v2/package.json
  3. 2
      packages/nc-gui-v2/plugins/tele.ts

18
packages/nc-gui-v2/components/smartsheet/Grid.vue

@ -1,12 +1,13 @@
<script lang="ts" setup>
import { Api } from 'nocodb-sdk'
import { useNuxtApp } from '#app'
import { useUser } from '~/composables/user'
const { tabMeta, meta } = defineProps({
tabMeta: Object,
meta: Object,
})
interface Props {
tabMeta: Record<string, any>
meta: Record<string, any>
}
const { tabMeta, meta } = defineProps<Props>()
const { project } = useProject()
const { user } = useUser()
@ -37,7 +38,7 @@ onMounted(async () => {
<v-table>
<thead>
<tr>
<th v-for="col in meta.columns">
<th v-for="(col, i) of meta.columns" :key="`${col.title}-${i}`">
{{ col.title }}
</th>
</tr>
@ -49,11 +50,6 @@ onMounted(async () => {
</th>
</tr>
</tbody>
<!-- <Column v-for="col in meta.columns" :key="col.id" :field="col.title" :header="col.title">
<template v-if="col.uidt === 'LinkToAnotherRecord'" #body="{data:{[col.title]:d}}">
{{ d && (Array.isArray(d) ? d : [d]).map(c1 => c1[Object.keys(c1)[1]]).join(', ') }}
</template>
</Column> -->
</v-table>
</div>
</div>

3
packages/nc-gui-v2/package.json

@ -4,7 +4,8 @@
"build": "nuxt build",
"dev": "nuxt dev",
"generate": "nuxt generate",
"preview": "nuxt preview"
"preview": "nuxt preview",
"lint": "eslint --ext \".js,.jsx,.ts,.tsx,.vue\" --fix --ignore-path .gitignore ."
},
"devDependencies": {
"@antfu/eslint-config": "^0.25.2",

2
packages/nc-gui-v2/plugins/tele.ts

@ -68,7 +68,7 @@ export default defineNuxtPlugin(async (nuxtApp) => {
},
})
function getListener(binding) {
return function (e) {
return function () {
if (!socket)
return

Loading…
Cancel
Save