Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] export * from 'xx' is in leaves result #369

Open
zhuqingyv opened this issue Apr 25, 2023 · 1 comment
Open

[BUG] export * from 'xx' is in leaves result #369

zhuqingyv opened this issue Apr 25, 2023 · 1 comment

Comments

@zhuqingyv
Copy link

// a.js
export const a = {}
// b.js
export const b = {}
// index.js
export * from 'a';
export * from 'b';
// madge.js
const madge = require('madge');
madge('index.js', {
      baseDir: './',
      fileExtensions: ['js', 'ts', 'tsx', 'jsx'],
      excludeRegExp: ['website', '.png', '.jpg'],
      // tsConfig: path.resolve(__dirname, './tsconfig.json')
    }).then((res) => {
      const list = res.leaves();
      fs.writeFileSync(path.resolve(__dirname, './result.json'), JSON.stringify(list, null, 2));
    });

output

[
  "a.js",
  "b.js",
]
@imakan
Copy link

imakan commented Sep 27, 2023

any answer?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants