LinkedInAttic/inject

Empty dependencies are different than no dependencies

jakobo opened this issue · 0 comments

requirejs/requirejs#669

// required file #1
define([], function(module) {
  // module should be undefined
});

// required file #2
define(function(require, module, exports) {
  // module should be defined
});

The problem: When an empty array is set for dependencies, then no require/module/exports should be made available.

Ultimately, this gets us compliant with the same behavior people expect in dojo and curl.