Trace direct importers
Use:
rev-dep imported-by --file src/utils/math.ts
This shows the direct importers of a file only - one hop, not the full chain from an entry point. Use it for fast local impact analysis before changing or moving a module.
--file is required.
Useful flags​
rev-dep imported-by --file src/utils/math.ts --count
rev-dep imported-by --file src/utils/math.ts --list-imports
--countprints only the number of importing files.--list-importsgroups output by file and shows the raw import request strings. This is useful when the same file is imported under different requests (relative path, alias, package entry).
For the full path from an entry point to a file, use resolve.