You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes as a developer you want to check the validity of your types without having to launch yarn serve, which takes more time. And even though you can check the types of the .ts files with tsc -p tsconfig.json --pretty --noEmitthis does not check.vue files. I haven't been able to reproduce the same command vue-cli-service executes, which is why I'm issuing this feature request.
Another reason why this would be interesting is to hook this command inside CI to fail the build if the types are not correct, because right now you can't do that, as the typing errors are shown on the command line as messages and do not have an exit code.
What does the proposed API look like?
vue-cli-service type [options]
Note that this should propagate TypeScript's options. For instance, the user should be able to pass the flag --noEmit in order for TypeScript not to compile, or whatever options.
The text was updated successfully, but these errors were encountered:
Just ran into the issue. I always assumed that it would check .vue files and was surprised when my build failed because of type errors, even though the typescript check was clear. This is especially bad, since refactoring .vue files doesn't work with VS Code, so the chance of type errors is much higher, because often they need to be manually updated.
What problem does this feature solve?
Sometimes as a developer you want to check the validity of your types without having to launch
yarn serve
, which takes more time. And even though you can check the types of the.ts
files withtsc -p tsconfig.json --pretty --noEmit
this does not check.vue
files. I haven't been able to reproduce the same command vue-cli-service executes, which is why I'm issuing this feature request.Another reason why this would be interesting is to hook this command inside CI to fail the build if the types are not correct, because right now you can't do that, as the typing errors are shown on the command line as messages and do not have an exit code.
What does the proposed API look like?
vue-cli-service type [options]
Note that this should propagate TypeScript's options. For instance, the user should be able to pass the flag
--noEmit
in order for TypeScript not to compile, or whatever options.The text was updated successfully, but these errors were encountered: