question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

TypeScript errors out of the box

See original GitHub issue

I have a Vue project with TypeScript, and just with this code block I’m getting a type error:

Argument of type 'PluginFunction<any>' is not assignable to parameter of type 'PluginObject<any> | PluginFunction<any>'.
import Vue from 'vue';
import Vuelidate from 'vuelidate';

Vue.use(Vuelidate);

Issue Analytics

  • State:open
  • Created 5 years ago
  • Reactions:2
  • Comments:18

github_iconTop GitHub Comments

10reactions
mvandakcommented, May 7, 2019

I had the same problem with similar tsconfig.json. I used yarn in project. As playgound worked fine and neighter deleting node_modules and reinstalling did not helped I expected some tsconfig issue. After some hours of many changes of tsconfig and googling, I found Jan Esser’s comment about two versions of vue in project (https://github.com/vuelidate/vuelidate/pull/287). Confirmed that this was the case.

Problem was caused by yarn duplicates of vue package in yarn.lock. Helped using yarn-deduplicate to fix duplicates followed by yarn install. It worked correctly now. Thank you Jan for good job.

2reactions
alvaro-canepacommented, May 31, 2020

@mvandak thanks, works fine. After that, close and re open VSC to get the changes.

Read more comments on GitHub >

github_iconTop Results From Across the Web

TypeScript errors and how to fix them
Below you find a list of common TypeScript errors along with the buggy code and its fixed version. If you're interested in more...
Read more >
suddenly typescript errors with tsconfig.json
When I try to debug a C# unittest via context action in the code editor window, the build suddenly fails with a lot...
Read more >
How to read TypeScript errors - HipsterBrown
When seeing TypeScript errors for the first time, they can range from helpful to WTF.
Read more >
Report typescript errors as warnings in Visual Studio and don't ...
I think msbuild watches the output for the word 'error'. When it does it flags an error. · These errors are identified by...
Read more >
Documentation - TypeScript 3.9
That's why TypeScript 3.9 brings a new feature: // @ts-expect-error comments. When a line is preceded by a // @ts-expect-error comment, TypeScript will...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found