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
... the "//" key will never be used by npm for any purpose, and is reserved for comments ... If you want to use a multiple line comment, you can use either an array, or multiple "//" keys.
depcheck reasonably thinks it's a dependency called // and reports it as unused.
Code snippets
Where the dependency is used:
It isn't
Where the dependency is listed in package.json:
"//": ["a comment"],
Versions
node -v: v18.17.0
npm -v: 9.6.7
depcheck --version: 1.4.7
Extra info
Any extra info you want to include. Thank you for the bug report!
BONUS POINTS: If you wish to help us debug further, the depcheck --json option will show more information. Check here in the README for documentation on json output.
The text was updated successfully, but these errors were encountered:
Bug Description
The officially suggested solution for comments in
package.json
is using//
as a key (https://groups.google.com/g/nodejs/c/NmL7jdeuw0M/m/yTqI05DRQrIJ, npm/npm#4482 (comment)):depcheck
reasonably thinks it's a dependency called//
and reports it as unused.Code snippets
Where the dependency is used:
Where the dependency is listed in package.json:
Versions
node -v
: v18.17.0npm -v
: 9.6.7depcheck --version
: 1.4.7Extra info
Any extra info you want to include. Thank you for the bug report!
BONUS POINTS: If you wish to help us debug further, the
depcheck --json
option will show more information. Check here in the README for documentation on json output.The text was updated successfully, but these errors were encountered: