File tree Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Expand file tree Collapse file tree 1 file changed +19
-1
lines changed Original file line number Diff line number Diff line change @@ -32,7 +32,23 @@ There are a few steps to do:
32
32
import('/@vite-plugin-checker-runtime-entry')
33
33
</script>
34
34
```
35
- 3 . Import component above in the root component of your Nuxt project to have a global error overlay.
35
+ 3 . Add vite-plugin-checker to ` vite.plugins ` in ` nuxt.config.ts ` .
36
+
37
+ ``` ts
38
+ import { checker } from ' vite-plugin-checker'
39
+ // https://nuxt.com/docs/api/configuration/nuxt-config
40
+ export default defineNuxtConfig ({
41
+ vite: {
42
+ plugins: [
43
+ checker ({
44
+ vueTsc: true ,
45
+ }),
46
+ ],
47
+ },
48
+ })
49
+ ```
50
+
51
+ 4 . Import component above in the root component of your Nuxt project to have a global error overlay.
36
52
37
53
``` vue
38
54
<script setup lang="ts">
@@ -49,6 +65,8 @@ There are a few steps to do:
49
65
</template>
50
66
```
51
67
68
+ You are all set in both development and build mode.
69
+
52
70
#### Enable vite-plugin-checker as a built-in Nuxt functionality
53
71
54
72
::: warning
You can’t perform that action at this time.
0 commit comments