We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 5f8469f commit d3082bdCopy full SHA for d3082bd
src/rules/no-unused-modules.js
@@ -453,9 +453,12 @@ module.exports = {
453
}
454
455
456
- const exportStatement = exports.get(exportedValue)
+ // exportsList will always map any imported value of 'default' to 'ImportDefaultSpecifier'
457
+ const exportsKey = exportedValue === DEFAULT ? IMPORT_DEFAULT_SPECIFIER : exportedValue
458
- const value = exportedValue === IMPORT_DEFAULT_SPECIFIER ? DEFAULT : exportedValue
459
+ const exportStatement = exports.get(exportsKey)
460
+
461
+ const value = exportsKey === IMPORT_DEFAULT_SPECIFIER ? DEFAULT : exportsKey
462
463
if (typeof exportStatement !== 'undefined'){
464
if (exportStatement.whereUsed.size < 1) {
0 commit comments