jaredhanson / passport-local

Username and password authentication strategy for Passport and Node.js.
https://www.passportjs.org/packages/passport-local/?utm_source=github&utm_medium=referral&utm_campaign=passport-local&utm_content=about
MIT License
2.74k stars 498 forks source link

Define main entry module to be a js file #103

Closed langma closed 9 years ago

langma commented 9 years ago

Define "main" to be a js module instead of a directory to enable certain tools (madge) to understand them. This is also how npm specification defines the data type: https://docs.npmjs.com/files/package.json

coveralls commented 9 years ago

Coverage Status

Coverage remained the same at 97.62% when pulling 9ed3772cbffe5965718133f99f24d2a7e052080b on langma:master into 33d420ba5f54939c85adc5e4b61009db6467a900 on jaredhanson:master.

jaredhanson commented 9 years ago

I think its more sensible for that madge be patched to handle main pointing to a directory. There are numerous modules on npm that point to directories, including most of mine, and I have no desire to go through and change them.

I don't see any requirement that main be a file in npm's package.json spec, or CommonJS for that matter. It is not implied that a module name resolve to a file, since you can require by directory names.