dev module exports

Analyze module export surfaces for pass-through re-exports

Command version
0.0.0
Command configuration
dev-tool:dev.module.exports@0.0.0

Arguments

ArgumentTypeRequiredDefaultDescription
--validate, --no-validatebooleanNofalseValidate module exports and flag pass-through re-exports as violations
--recurse, --no-recursebooleanNofalseValidate every repository this one pins as well, each in its own checkout by its own manifest -- what its own gate reads standing alone -- and the adapter checkout a tracked adapter catalog pins among them. A run from a tree's root otherwise reads the root's manifest, whose modules are the pinned repositories and hold no export surface of their own. Refused without --validate

It also takes the global arguments.

Output

It answers with a exports.moduleExportsResult.

Types

exports.moduleExportsResult

FieldTypeRequiredDefaultDescription
moduleCountintegerYesHow many modules the manifest declares
parentModulesWithSubmodulesCountintegerYesHow many of those modules declare submodules
exportSurfaceCheckCountintegerYesHow many parent modules were taken up for analysis, one per module that declares submodules; one with no export surface is counted all the same
passThroughReexportIssueslist[exports.PassThroughReexportIssue]No[]Each symbol a parent module's export surface imports from another module and exports unchanged
validatedbooleanNofalseWhether --validate was given, under which any issue fails the run as PARENT_EXPORT_VALIDATION_FAILED
isValidbooleanNofalseWhether --validate was given and found no issue; false where it was not given

exports.PassThroughReexportIssue

FieldTypeRequiredDefaultDescription
parentModulestringYesThe module whose export surface holds the re-export
exportFilestringYesThe file name of that export surface, without its directory
importedSymbolstringYesThe name the symbol is imported under
symbolSourcestringYesWhere the symbol is imported from: the module that owns the imported package, by name or coordinate, or the import path as written where no module is known to own it
reexportedSymbolstringYesThe name the symbol is exported under, which is the name it was imported under
lineNumberintegerNo0The line of exportFile the import is on, counted from 1