scalableminds / amd-optimize

An AMD (RequireJS) optimizer that's stream-friendly. Made for gulp.
MIT License
162 stars 29 forks source link

amd-optimize finding circular references when require.js isn't. #50

Open William-Owen opened 9 years ago

William-Owen commented 9 years ago

I have a project that is currently using Grunt and require.js and I am trying to move it over to gulp and amd-optimize.

The problem is that amd-optimize is breaking with a ' Circular dependency detected.' error.

Is there any reason why amd-optimize might return such an error when require.js doesn't when processing the same codebase.

normanrz commented 9 years ago

Hi, it is a known limitation that amd-optimize does not support circular dependencies, but requirejs does (under some circumstances). The reason is mainly that I didn't have time to implement it and I suppose it is quite hard to integrate in the current code architecture. I'm happy to review any PR on this, though!