File tree Expand file tree Collapse file tree 2 files changed +14
-6
lines changed
packages/create-app/template-vue-ts/src Expand file tree Collapse file tree 2 files changed +14
-6
lines changed Original file line number Diff line number Diff line change 11<template >
22 <img alt =" Vue logo" src =" ./assets/logo.png" />
3- <HelloWorld msg =" Hello Vue 3 + Vite" />
3+ <HelloWorld msg =" Hello Vue 3 + TypeScript + Vite" />
44</template >
55
66<script lang="ts">
Original file line number Diff line number Diff line change 77 </p >
88
99 <p >
10- Recommended setup:
10+ Recommended IDE setup:
1111 <a href =" https://code.visualstudio.com/" target =" _blank" >VSCode</a >
1212 +
1313 <a
2121 >Vue DX</a >
2222 </p >
2323 <p >
24- Make sure to use workspace version of TypeScript to get improved support via
24+ If using & lt ; script setup & gt ; : use
2525 <a
26- href =" https://github.com/znck/vue-developer-experience "
26+ href =" https://github.com/johnsoncodehk/volar "
2727 target =" _blank"
28- >@vuedx</a >.
29- <br />Note @vuedx is still experimental and this setup is provided for early feedback.
28+ >Volar</a > instead (and disable Vetur)
29+ </p >
30+ <p >
31+ <b style =" color :red " >Make sure to use workspace version of TypeScript!!!</b >
32+ <br />This leverages the
33+ <code >@vuex/typescript-plugin-vue</code > to provide types for `*.vue` imports.
34+ <br />1. Open
35+ <code >src/main.ts</code > in VSCode
36+ <br />2. Open VSCode command input
37+ <br />3. Search and run "Select TypeScript version" -> "Use workspace version"
3038 </p >
3139 <button @click =" count++" >count is: {{ count }}</button >
3240 <p >
You can’t perform that action at this time.
0 commit comments