-
Notifications
You must be signed in to change notification settings - Fork 44
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
what should I do if I don't want to parse the module from node_module? for example, import * as api from 'util', 'util' is not a node_module, it is a file under the current path. #70
Comments
Are you using Madge or this lib directly? Madge, specifically the dependency tree lib that it uses supports a filter argument to exclude node modules from being traversed. |
Yes,i use the dependency-tree.I know the filter argument, but what I want to express, If my code "import util form "util"", "util" is a file under the current dir, not a node module. but the dependency-tree parses it as a node module.so, the "util" will be add to the "noExistent". so, if I don't want to edit the code, can the dependency-tree provide a argument to solve this problem? Thank you ! |
Thanks for the additional context. Would you be able to share your dependency-tree config? I'm curious as to the options being turned on (namely if you're setting es6's mixed imports). |
This is my code. I hope the dependency-tree can look up the module "util" under the current dir first. it actually is a file "./util.js". And if it doesn't exist, look up the node_modules dir secondly. Thank you ! |
Thanks! I'll have to trace it to see what's happening in filing-cabinet. It could be a bug. Thanks for reporting. |
I think it is not a bug. because “import uitl from "./util.js" ” is a better code, " import util from "util" " is nonstandard. but I hope you can make it more compatible to solve this problem. Thank you ! |
No description provided.
The text was updated successfully, but these errors were encountered: