eslint-plugin-import icon indicating copy to clipboard operation
eslint-plugin-import copied to clipboard

[New] `no-unused-modules`: Add `ignoreUnusedTypeExports` option

Open silverwind opened this issue 1 year ago • 8 comments
trafficstars

Fixes: https://github.com/import-js/eslint-plugin-import/issues/2694

silverwind avatar May 28 '24 20:05 silverwind

Will tweak tests a bit.

silverwind avatar May 28 '24 20:05 silverwind

Ok, tests are fine now.

silverwind avatar May 28 '24 20:05 silverwind

This seems great, except that it's best when boolean arguments default to false. Can you come up with an alternative name for it so it can default to false?

ljharb avatar May 28 '24 20:05 ljharb

This seems great, except that it's best when boolean arguments default to false. Can you come up with an alternative name for it so it can default to false?

Hmm I could invert the name and function but thought that the current name matches nicely into the existing options missingExports and unusedExports.

silverwind avatar May 28 '24 20:05 silverwind

Inverted it, so now it's ignoreUnusedTypeExports defaulting to false.

silverwind avatar May 28 '24 20:05 silverwind

Your original option name definitely did match better, but i prioritize booleans defaulting to false over option names :-) thanks!

ljharb avatar May 28 '24 20:05 ljharb

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 96.02%. Comparing base (fc361a9) to head (e96db1a).

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3011   +/-   ##
=======================================
  Coverage   96.02%   96.02%           
=======================================
  Files          78       78           
  Lines        3296     3299    +3     
  Branches     1158     1160    +2     
=======================================
+ Hits         3165     3168    +3     
  Misses        131      131           

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

codecov[bot] avatar May 28 '24 21:05 codecov[bot]

This CI failures seem intermittent and the coverage annotation "Added line #L518 was not covered by tests" is incorrect, I verified the line is being hit during tests.

silverwind avatar Jun 20 '24 20:06 silverwind

node 22.5 itself is broken rn, so i'll rerun those failing jobs once a fixed 22.5.1 is released.

ljharb avatar Jul 18 '24 22:07 ljharb