node package manager
Orgs are free. Discover, share, and reuse code in your team. Create a free org »



This node.js module will load a collection of modules and expose them as GLOBAL.

Install it

npm install globalizer --save

Use it

require('globalizer')(['path', 'assert', {
    _: 'lodash',
    gutil: 'gulp-util',
    request: 'supertest',
    Deferred: 'JQDeferred',
    io: '',
    config: '../../config'

Is identical to :

GLOBAL.path = require('path');
GLOBAL.assert = require('assert');
GLOBAL._ = require('lodash');
GLOBAL.gutil = require('gulp-util');
GLOBAL.request = require('supertest');
GLOBAL.Deferred = require('JQDeferred'); = require('');
GLOBAL.config = require('../../config');