knip icon indicating copy to clipboard operation
knip copied to clipboard

False negative when name is used as property

Open neelmraman opened this issue 1 year ago • 1 comments

Hi, thanks again for your work on this project and sorry for the numerous bug reports over the past few days.

I found a new issue where exports are not marked as unused if the same name is also used as a property (and I imagine there could be other contexts as well that similarly mask the usage of the export). Here is a repro.

neelmraman avatar Jun 27 '24 00:06 neelmraman

Yeah, duplicate names are support by TypeScript, but not Knip unfortunately.

webpro avatar Jun 27 '24 10:06 webpro

Until this is reported more often as problematic, won't fix.

webpro avatar Nov 03 '24 07:11 webpro