Typescript Support
little3201 opened this issue ยท 6 comments
little3201 commented
has typescript support plan ?
JanGuillermo commented
Hi @little3201!
This has been planned, although I haven't gotten to it. I'll get back to you later in this thread.
jackywu commented
I guess it is the same problem.
vue 3 + typescript
ERROR in src/components/modules/Markdown.vue:7:27
TS7016: Could not find a declaration file for module 'vue3-markdown-it'. '/Users/wc/codebase/my-project/QuantiInvestSystem/frontend/node_modules/vue3-markdown-it/dist/vue3-markdown-it.umd.min.js' implicitly has an 'any' type.
Try `npm i --save-dev @types/vue3-markdown-it` if it exists or add a new declaration (.d.ts) file containing `declare module 'vue3-markdown-it';`
5 | <script lang="ts">
6 | import { defineComponent } from "vue";
> 7 | import VueMarkdownIt from "vue3-markdown-it";
| ^^^^^^^^^^^^^^^^^^
8 |
9 | export default defineComponent({
10 | name: "markdown",
Artmorse commented
Yes, i've the same issue...
jannikbuscha commented
Yes, i've the same issue...
๐
if not exist, create a shims-vue.d.ts file (next to package.json) and write in that file: declare module 'vue3-markdown-it';
mauriciabad commented
Typescript support should be pretty easy to add, just rename the files to .ts
, use defineComponent
and use PropType
.
HugoJBello commented
Yes, i've the same issue... disappointed
if not exist, create a shims-vue.d.ts file (next to package.json) and write in that file:
declare module 'vue3-markdown-it';
better in the src folder