views:

52

answers:

1

I have a node.js module like this:

# couchdb.js

var couchdb = {
  // code
}

module.exports = couchdb;

How do I do to be able to use require("couchdb") in all my files?

+1  A: 

Put your module into folder ~/.node_libraries/ to make it available for all scripts

Andris