aackerman / circular-dependency-plugin

Detect circular dependencies in modules compiled with Webpack
https://www.npmjs.com/package/circular-dependency-plugin
ISC License
914 stars 46 forks source link

TypeError: Path must be a string. Received undefined #28

Closed tanekim88 closed 6 years ago

tanekim88 commented 6 years ago

I see a flaw in the code. On top, it uses "let cwd = process.cwd()". This will not work if I run webpack in different directory. Many people nowadays have separate Server and Client folders. And the server runs webpack on client folder when building. At that point, cwd=process.cwd() will be a server path, while cwd is supposed to be Client path. Please at least give an option for a user to customize cwd.