Flotype / now

NowJS makes it easy to build real-time web apps using JavaScript
http://www.nowjs.com
MIT License
1.91k stars 175 forks source link

Dependencies included multiple times in npm package #116

Closed isaacs closed 13 years ago

isaacs commented 13 years ago

The npm package for now.js is pretty huge, despite the fact that it is a relatively small program. Here's why:

  1. include/Socket.IO Since socket.io is already listed as a dep, it seems unnecessary to put it in ./include as well.
  2. redis, hiredis, and ain are installed in node_modules, but not listed as dependencies, so they get bundled with the package.

I'd recommend:

  1. Remove include/Socket.IO (or adding it to a .npmignore file) in favor of doing require("socket.io") to get the npm-installed dependency
  2. List redis, hireds, and ain as dependencies if they're required, or remove them if they're not (the npm prune command can do this for you)
isaacs commented 13 years ago

That would bring the file count down from 989 to 24.

sridatta commented 13 years ago

Thanks for informing us, Isaac. I forced a publish so that future installs won't have the extra cruft.

isaacs commented 13 years ago

Ah, much nicer!