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
When I save this file, it will be auto fixed: the side effect import disappears, and the named import becomes a type import, Then I lost the ./my-element import;
TypeScript doesn't know anything about external lint programs and can't adjust its behavior accordingly, so the contents of your .eslintrc.js aren't relevant in this situation.
I have a typescript project that includes the following configurations:
.vscode/settings.json
.eslintrc.js
Now I have a file that defines a customElement
my-element.ts
;Usually, I directly import it as side effect;
Sometimes I need to use its type, when I input
MyElement
, Intellisense or Quick fix will add a named import, which violated the eslint rules.When I save this file, it will be auto fixed: the side effect import disappears, and the named import becomes a type import, Then I lost the
./my-element
import;If we have an "Add import type from './my-element.ts'" option in Intellisense & Quick fix, we can solve this problem.
The text was updated successfully, but these errors were encountered: