yuyz0112 / vue-type-check Goto Github PK
View Code? Open in Web Editor NEWa type checker for typescript written Vue components
Home Page: http://www.myriptide.com/vue-type-check/
a type checker for typescript written Vue components
Home Page: http://www.myriptide.com/vue-type-check/
<div v-if="foo !== null">
{{ foo.content }}
</div>
274:11 Object is possibly 'null'.
272 | <div>
> 274 | {{ foo.content }}
| ^^^^^^^
275 | </div>
276 | </template>
Vetur doesn't complain about this. I don't really know what to do about it.
$ npx vue-type-check --onlyTemplate --workspace . (10-16 16:48)
Error: Debug Failure. Expected 3 === 1. Registered script kind should match new script kind. /home/hentai/projects/waruimono/embeddedui/node_modules/@vue/cli-plugin-router/generator/template/src/App.vue.template
at Object.assertEqual (/home/hentai/projects/waruimono/embeddedui/node_modules/typescript/lib/typescript.js:2193:17)
at Object.getOrCreateSourceFileByPath [as getSourceFileByPath] (/home/hentai/projects/waruimono/embeddedui/node_modules/typescript/lib/typescript.js:135818:34)
at tryReuseStructureFromOldProgram (/home/hentai/projects/waruimono/embeddedui/node_modules/typescript/lib/typescript.js:98326:28)
at Object.createProgram (/home/hentai/projects/waruimono/embeddedui/node_modules/typescript/lib/typescript.js:97915:30)
at synchronizeHostData (/home/hentai/projects/waruimono/embeddedui/node_modules/typescript/lib/typescript.js:135741:26)
at Object.getSemanticDiagnostics (/home/hentai/projects/waruimono/embeddedui/node_modules/typescript/lib/typescript.js:135858:13)
at VueInterpolationMode.doValidation (/home/hentai/projects/waruimono/embeddedui/node_modules/vue-language-server/dist/modes/template/interpolationMode.js:38:56)
at /home/hentai/projects/waruimono/embeddedui/node_modules/vue-type-check/dist/index.js:77:47
at Generator.next (<anonymous>)
at fulfilled (/home/hentai/projects/waruimono/embeddedui/node_modules/vue-type-check/dist/index.js:5:58)
Hi. Does this run on Windows?
The tool runs well for our developers running Linux but just exits on our machines running Windows with no errors.
I spent a bit of time picking through the code and noticed the walk
function in index.js concats 'file://' to the fs path which won't be valid in Windows. But after fixing that I just ran into problems deeper into the language service where files were not being found.
I haven't got the time to investigate this further at the moment so thought i'd raise it here to see if anyone has a solution.
Subj
--onlyTypeScript support was merged #8
But never published to npm
Can the typescript version be updated to 4.0 in package.json
?
Can we have this support in an editor like VS Code
The latest commit in this repository is 84b308 (Jul 16, 2020), but the source npm package includes is older.
In the result, vtc installed from npm does not work at all currently.
Specifically, tests fail when you use the source published to npm.
Could you republish this package to npm?
I have a project that is open in VS code that has the Vetur extension working with interpolation is showing errors in various templates.
I am executing vue-type-check with "vtc --workspace ./" in the command line but nothing is being returned. It is the same if I include --srcDir ./path/to/nested/component.
Please provide some further information and/or a test example that should work.
Regards
There's no reason for users of this package to have those dependencies installed when installing vue-type-check.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.