Consistently resolve imports only in pathToModuleName
Some transformers used to call ts.resolveModuleName to resolve imports to a file name. The googmodule transformer even had a option convertIndexImportShorthand to toggle that behavior. We never made use of this option, though.
In all cases the code eventually calls pathToModuleName, which needs to call ts.resolveModuleName, too, because the import may not be resolved, yet.
This change removes all ts.resolveModuleName calls and relies on pathToModuleName doing it. It also removes the now unnecessary convertIndexImportShorthand and moduleResolutionHost properties in the googmodule host.
Consistently resolve imports only in pathToModuleName
Some transformers used to call
ts.resolveModuleName
to resolve imports to a file name. The googmodule transformer even had a optionconvertIndexImportShorthand
to toggle that behavior. We never made use of this option, though.In all cases the code eventually calls
pathToModuleName
, which needs to callts.resolveModuleName
, too, because the import may not be resolved, yet.This change removes all
ts.resolveModuleName
calls and relies onpathToModuleName
doing it. It also removes the now unnecessaryconvertIndexImportShorthand
andmoduleResolutionHost
properties in the googmodule host.