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

Review settings for type vs value imports #217

Open
luxaritas opened this issue Mar 8, 2023 · 0 comments
Open

Review settings for type vs value imports #217

luxaritas opened this issue Mar 8, 2023 · 0 comments
Labels
priority: p3/standard Enhancement with nominal value or bug with nominal impact scope: tsconfig size: md type: bug Something isn't working

Comments

@luxaritas
Copy link
Member

  • When working on our new Nest project, I noticed an issue where when VS Code auto-imported classes for use with dependency injection, it would import them as type-only, even though they needed to be imported as values to be included properly for dependency injection via emitDecoratorMetadata/reflect-metadata. I wound up setting "preserveValueImports": false and "importsNotUsedAsValues": "remove" on that project for now.
  • TS 5 has deprecated preserveValueImports and importsNotUsedAsValues in favor of the new verbatimModuleSyntax

Once TS 5 is out (slated for the 14th), we'll need to review this to hopefully ensure:

  • Our configuration still works with Vue script setup
  • We avoid confusing errors due to auto-imports incorrectly choosing type-only imports
  • Module elision still works when it needs to (or determine we don't care if esbuild's tree-shaking is sufficient)
@luxaritas luxaritas added type: bug Something isn't working scope: tsconfig size: md priority: p3/standard Enhancement with nominal value or bug with nominal impact labels Mar 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
priority: p3/standard Enhancement with nominal value or bug with nominal impact scope: tsconfig size: md type: bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant