pahen / madge

Create graphs from your CommonJS, AMD or ES6 module dependencies
MIT License
8.71k stars 312 forks source link

require statement is not detected by madge #385

Open yesgp opened 11 months ago

yesgp commented 11 months ago

I am trying to check the circular dependencies using madge command as follows. But madge is skipping require statement and not listing the dependency.

Command that was ran:

madge --extensions ts -i test.svg . > log2.txt Eg. Below line is present in a typescript file. but, module1 was not listed in dependencies list.

const { myconstant } = require("../module1");

Any idea how to make madge look for require statement as well along with import?