Problem with typescript
See original GitHub issuenode_modules/vue3-apexcharts/typings/vue-apexcharts.d.ts:2:30 - error TS2307: Cannot find module 'vue/types/plugin' or its corresponding type declarations.
2 import { PluginObject } from 'vue/types/plugin';
~~~~~~~~~~~~~~~~~~
node_modules/vue3-apexcharts/typings/vue-apexcharts.d.ts:5:42 - error TS2709: Cannot use namespace 'Vue' as a type.
5 interface VueApexChartsComponent extends Vue {
~~~
node_modules/vue3-apexcharts/typings/vue-apexcharts.d.ts:36:59 - error TS2709: Cannot use namespace 'Vue' as a type.
36 declare const VueApexCharts: Component & ComponentOptions<Vue> & PluginObject<any>;
Thanks for the great project! Unfortunately I’ve been unable to use it due to this error. Any recommendations?
Issue Analytics
- State:
- Created 2 years ago
- Comments:10 (10 by maintainers)
Top Results From Across the Web
The problem with Typescript - zackoverflow.dev
The primary problem is tsc is slow. Deno has addressed this as the TSC bottleneck, and it's a result of the fact that...
Read more >The Trouble with TypeScript - DEV Community
TypeScript doesn't improve productivity or readability. It doesn't particularly improve on modern JavaScript feature set. If anything it ...
Read more >Playground Example - Errors - TypeScript
By default TypeScript doesn't provide error messaging inside JavaScript. Instead the tooling is focused on providing rich support for editors.
Read more >7 really good reasons not to use TypeScript - everyday.codes
It does not solve the problem : JavaScript does indeed have many problems. TypeScript solves a great many of them through excellent tooling....
Read more >Issues · microsoft/TypeScript - GitHub
TypeScript is a superset of JavaScript that compiles to clean JavaScript output. - Issues · microsoft/TypeScript.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Some errors into TS typings I see there:
https://github.com/apexcharts/vue3-apexcharts/blob/883b047c35891008913abb3fa6f513259ed41b64/typings/vue-apexcharts.d.ts#L2 Should be
import { Plugin } from "vue"
. NoticePlugin
is a replacement for both oldPluginFunction
andPluginObject
and that it doesn’t have a generic parameter anymore.https://github.com/apexcharts/vue3-apexcharts/blob/883b047c35891008913abb3fa6f513259ed41b64/typings/vue-apexcharts.d.ts#L1 https://github.com/apexcharts/vue3-apexcharts/blob/883b047c35891008913abb3fa6f513259ed41b64/typings/vue-apexcharts.d.ts#L36 https://github.com/apexcharts/vue3-apexcharts/blob/883b047c35891008913abb3fa6f513259ed41b64/typings/vue-apexcharts.d.ts#L5
Vue
namespace isn’t exported as an interface anymore and cannot be used as such. AFAIKinterface VueApexChartsComponent extends ComponentPublicInstance
should be used instead.https://github.com/apexcharts/vue3-apexcharts/blob/883b047c35891008913abb3fa6f513259ed41b64/typings/vue-apexcharts.d.ts#L40
The method to augment Vue instance with custom properties changes, you should now use
Hey, I checked your PR.
addText
is no longer relevant.setLocale
is still there (not documented currently though)