Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why ts error in .vue file can not be displayed in Vite HMR overlay #56

Closed
duola8789 opened this issue Jul 26, 2021 · 4 comments · Fixed by #59
Closed

Why ts error in .vue file can not be displayed in Vite HMR overlay #56

duola8789 opened this issue Jul 26, 2021 · 4 comments · Fixed by #59
Labels
bug Something isn't working

Comments

@duola8789
Copy link

My IDE is Webstorm, I can get ts error in Typescript terminal, but it can not be dispalyed in Vite HMR overlay

export default defineComponent({
    name: 'App',
    components: {
        HelloWorld
    },
    setup() {
        const a = ref<string>(22223);
        a.value = 22212;
        return {a};
    }
});

image

And Vite HMR overlay also doesn't show the error

image

is is possible to show the error on broswer just like Vue CLI?

image

@fi3ework
Copy link
Owner

Could you provide a minimal way to reproduce this project?

@duola8789
Copy link
Author

Could you provide a minimal way to reproduce this project?

https://github.com/duola8789/vite-ts

You could use this repository to reproduce, and the ts type error could be found at app.vue
thanks

@fi3ework
Copy link
Owner

fi3ework commented Jul 27, 2021

@duola8789 Thanks. I reproduce the demo. It can be fixed with a little tweak to VLS initial configuration (for VTI, it works. the plugin is heavily based on VTI, so it should work, too). But it needs a little more work to fix in this plugin. I'll fix it these days.

@fi3ework fi3ework added the bug Something isn't working label Jul 27, 2021
@duola8789
Copy link
Author

@fi3ework thanks

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants