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
In a fresh file, the first suggestion TS makes for where to import some (but not all) functions is from ad-hok/lib/* rather than ad-hok. See this example:
In my editor (Emacs + lsp-mode), this makes it very easy to import the functions from the incorrect place, as accepting the autocomplete suggestion as you type the function name will automatically add the wrong import.
Also, the type of the functions if you import from the wrong place is incorrect. This seems to be the difference between the type of the actual function vs the "Published" type:
In a fresh file, the first suggestion TS makes for where to import some (but not all) functions is from
ad-hok/lib/*
rather thanad-hok
. See this example:In my editor (Emacs + lsp-mode), this makes it very easy to import the functions from the incorrect place, as accepting the autocomplete suggestion as you type the function name will automatically add the wrong import.
Also, the type of the functions if you import from the wrong place is incorrect. This seems to be the difference between the type of the actual function vs the "Published" type:
The lib version imports
addWrapper
directly, while the correctaddWrapper
import has the type ofAddWrapperPublishedType
.I don't know if it's possible to control this, but it'd be nice to hint to TS that it should never import the "lib" versions of the functions.
The text was updated successfully, but these errors were encountered: