cujojs / curl

curl.js is small, fast, extensible module loader that handles AMD, CommonJS Modules/1.1, CSS, HTML/text, and legacy scripts.
https://github.com/cujojs/curl/wiki
Other
1.89k stars 216 forks source link

don't defer module definition unless using CommonJS-wrapped module #149

Closed unscriptable closed 11 years ago

unscriptable commented 11 years ago

Right now, curl uses deferred dependency resolution whenever the module uses the "exports" or "module" pseudo-modules. It should only do this if the dev is also using the CommonJS-wrapped define() signature, as well:

define(function(require, exports, module) {});

It should not do this when the dev specifies the CommonJS pseudo-modules like this:

define(["require", "exports", "module", function(require, exports, module) {});

cc @bryanforbes

unscriptable commented 11 years ago

closing this since it's fixed in dev08 branch.