tomblachut / svelte-intellij

Svelte components in WebStorm and friends
MIT License
485 stars 38 forks source link

Different tooltips for same variable (typescript) #227

Closed Treverix closed 3 years ago

Treverix commented 3 years ago

I noticed that the plugin sometimes shows different tooltips for the same variable. The tooltip on the first image is probably the correct one.

image

image

tomblachut commented 3 years ago

Hi! Does the same problem appear in JS file?

Treverix commented 3 years ago

No... only on typescript mode... on js, it's all good :)

here's a simple example:

<script lang="ts">
    import {writable} from 'svelte/store'
    const w = writable(false);
    const unsubscribe = w.subscribe((newValue) => console.log('changed to ' + newValue))
    unsubscribe();
</script>

<div></div>

image

image

tomblachut commented 3 years ago

I meant outside of Svelte, can you observe same problem in JS file vs TS file?

Treverix commented 3 years ago

Ah sorry - got it :) Now it looks like a bug in the IDEA typescript plugin - it happens on normal typescript files also, you just inherit their bug.

image

I file it on their youtrack.

tomblachut commented 3 years ago

Ok, thanks for clarification!

Treverix commented 3 years ago

https://youtrack.jetbrains.com/issue/WEB-51306