Just put your component in NPM. The more your application looks like a
nested tree of packages the easier things get.


On Fri, Feb 8, 2013 at 5:24 PM, Geerten van Meel <klova...@gmail.com> wrote:

> Hi,
>
> I am working on an app and would like to access a component of my
> app simply using require('component') instead of require('./component')or 
> worse
> require('./path/to/component.js'). I know that there are ways to achieve
> this by doing some hack regarding the node_modules folder, but I would like
> to ask whether there is a simple, elegant way to achieve this result (and
> not interfere with npm when deploying)?
>
> To summarize:
>
>  - I would like to include an app component using require('component')instead 
> of
> require('./path/to/component.js').
>
>  - The components location should ideally be somewhere out of node_modules
> in order to not mess with npm.
>
>  - NODE_PATH, thus process arguments should not be provided via the
> command line.
>
> Thank you for your time and suggestions!
>
> Geerten
>
> --
> --
> 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 nodejs@googlegroups.com
> To unsubscribe from this group, send email to
> nodejs+unsubscr...@googlegroups.com
> 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 nodejs+unsubscr...@googlegroups.com.
> For more options, visit https://groups.google.com/groups/opt_out.
>
>
>

-- 
-- 
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 nodejs@googlegroups.com
To unsubscribe from this group, send email to
nodejs+unsubscr...@googlegroups.com
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 nodejs+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.


Reply via email to