npm.io
0.0.1 • Published 12 years ago

bulk-load

Licence
MIT
Version
0.0.1
Deps
0
Vulns
0
Weekly
0

bulk-load

Loads and or globalizes all files in a given directory

Install

npm install bulk-load

Usage

var bulk = require('bulk-load')

Require every js file in lib/routes

bulk.load(__dirname + '/lib/routes')

Require every js file in lib/models and globalize the exports. If the directory contains a user.js file which exports a create function, the following is possible.

bulk.globalize(__dirname + '/lib/models')
User.create();

Keywords