I'm sending a response back to mailing list 'cause I was being stupid and
sent it to private...


>> There is a good reason. If a github repository will cease to exist
somehow, it ensures that docs and examples won't be lost.
> npm shouldn't be considered a backup solution

So what?...It's customary in opensource world to distribute all sources
with packages. For example, for every .deb file in Debian repository there
is a .tar.gz file with source code. Debian repository isn't a backup
solution, right? But sources are all there.


>> Documentation usually don't take much space. Well... everybody knows
that developers hate writing documentation, right? :)
> tests/examples/docs usually take up the MOST space

So you suggest to remove 5 Kb of documentation from 7 Kb module to save
space, right? Pretty nice idea, guess why I don't agree with that.


>> So I guess there are no good reasons to NOT keep it in published npm
packages.
> Except if you need to deploy on a bad internet connection. this isn't a
problem for your typical simcity 6, xbox one user, but not everyone has a
good net connection.

If you have a bad internet connection, you are in trouble anyway. npm
registry serving package metadata uncompressed, and you'll be downloading
800kb of metadata instead of 30kb compressed data. I think this question
should be attended to first. :)


>> npm packages contain too much garbage anyway. I'm talking about optional
dependencies. For example, AFAIR restify depend on a 5MB spdy library even
though very few people use spdy. So there's no point to try to save
diskspace I guess, 'cause nobody doing that anyway.
> I'm deploying on a device that doesn't have much diskspace or network
bandwidth.

Then you should be able to remove docs and tests somehow... Hm... yes, I
guess a command like `npm strip` to remove those can sometimes make sense.


>> And yes, there is a 3rd party module/tool. I think you can use
browserify to strip all this stuff and concatenate it to one js file. And
you can minimize this file later hoping that v8 would load it faster. I
didn't try that though. :)
> This is not for browser.

What is the difference? It's the same javascript.



On Thu, Jun 13, 2013 at 6:46 PM, Tim Oxley <[email protected]> wrote:

> haha, thanks for the response, I'm going to disagree with everything :D
>
> > There is a good reason. If a github repository will cease to exist
> somehow, it ensures that docs and examples won't be lost.
>
> npm shouldn't be considered a backup solution
>
> > Documentation usually don't take much space. Well... everybody knows
> that developers hate writing documentation, right? :)
>
> tests/examples/docs usually take up the MOST space
>
> > So I guess there are no good reasons to NOT keep it in published npm
> packages.
>
> Except if you need to deploy on a bad internet connection. this isn't a
> problem for your typical simcity 6, xbox one user, but not everyone has a
> good net connection.
>
> > npm packages contain too much garbage anyway. I'm talking about optional
> dependencies. For example, AFAIR restify depend on a 5MB spdy library even
> though very few people use spdy. So there's no point to try to save
> diskspace I guess, 'cause nobody doing that anyway.
>
> I'm deploying on a device that doesn't have much diskspace or network
> bandwidth.
>
> > And yes, there is a 3rd party module/tool. I think you can use
> browserify to strip all this stuff and concatenate it to one js file. And
> you can minimize this file later hoping that v8 would load it faster. I
> didn't try that though. :)
>
> This is not for browser.
>
> :D
>
>
>  On 13 June 2013 20:12, Alex Kocharin <[email protected]> wrote:
>
>>
>> There is a good reason. If a github repository will cease to exist
>> somehow, it ensures that docs and examples won't be lost. Documentation
>> usually don't take much space. Well... everybody knows that developers hate
>> writing documentation, right? :)
>>
>> So I guess there are no good reasons to NOT keep it in published npm
>> packages.
>>
>> npm packages contain too much garbage anyway. I'm talking about optional
>> dependencies. For example, AFAIR restify depend on a 5MB spdy library even
>> though very few people use spdy. So there's no point to try to save
>> diskspace I guess, 'cause nobody doing that anyway.
>>
>> And yes, there is a 3rd party module/tool. I think you can use browserify
>> to strip all this stuff and concatenate it to one js file. And you can
>> minimize this file later hoping that v8 would load it faster. I didn't try
>> that though. :)
>>
>>
>>
>> On Thursday, June 13, 2013 11:44:23 AM UTC+4, Tim Oxley wrote:
>>>
>>> Is there a good reason we should be keeping docs/examples etc in
>>> published npm packages?
>>>
>>> While this stuff is sometimes useful in development, it would be fun if
>>> there was way to easily generate a slim node_modules folder for a
>>> deployment that is devoid of anything that isn't executable in a production
>>> environment, e.g. examples, tests and documentation
>>>
>>> Perhaps some kind of "production/development" flag inside .npmignore?
>>>
>>> Anyone have a good solution for this? A 3rd party module/tool?
>>>
>>
>

-- 
-- 
Job Board: http://jobs.nodejs.org/
Posting guidelines: 
https://github.com/joyent/node/wiki/Mailing-List-Posting-Guidelines
You received this message because you are subscribed to the Google
Groups "nodejs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/nodejs?hl=en?hl=en

--- 
You received this message because you are subscribed to the Google Groups 
"nodejs" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to