From c6c6722d38eb850a99fb3bcdd6567c6d6de77f76 Mon Sep 17 00:00:00 2001 From: Johnson Chu Date: Sun, 14 Feb 2021 14:26:59 +0800 Subject: [PATCH] feat: enable volar ts plugin (#63) * chore: enabled ts plugin * fix: require -> required --- .vscode/settings.json | 1 + src/pages/hi/[name].vue | 2 +- src/shims.d.ts | 6 ------ 3 files changed, 2 insertions(+), 7 deletions(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index 8b18ad2..8c3bd8e 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -1,4 +1,5 @@ { + "volar.tsPlugin": true, "i18n-ally.localesPaths": "locales", "i18n-ally.keystyle": "nested", "i18n-ally.sortKeys": true, diff --git a/src/pages/hi/[name].vue b/src/pages/hi/[name].vue index e315994..5cfbcf2 100644 --- a/src/pages/hi/[name].vue +++ b/src/pages/hi/[name].vue @@ -6,7 +6,7 @@ import { defineProps } from 'vue' const props = defineProps({ name: { type: String, - require: true, + required: true, }, }) diff --git a/src/shims.d.ts b/src/shims.d.ts index 20a428b..3da5079 100644 --- a/src/shims.d.ts +++ b/src/shims.d.ts @@ -4,12 +4,6 @@ declare interface Window { // extend the window } -declare module '*.vue' { - import { ComponentOptions } from 'vue' - const component: ComponentOptions - export default component -} - // with vite-plugin-md, markdowns can be treat as Vue components declare module '*.md' { import { ComponentOptions } from 'vue'