canjs / can-util

Essential utilities used by lots of CanJS's projects.
https://canjs.com/doc/can-util.html
MIT License
10 stars 8 forks source link

Make each module assign to can-namespace separately #418

Closed chasenlehara closed 6 years ago

chasenlehara commented 6 years ago

Importing can-util/can-util.js causes all of the dom/js modules to be assigned to can-namespace. This is useful but prevents can-util from being imported into the main 4.0 build because some of the modules depend on different package versions that conflict in 4.0

This commit changes how modules are assigned to can-namespace; now, each module is responsible for doing it on its own, instead of having them all done in can-util.js, which means parts of can-util can be imported and assigned to the main namespace while avoiding dependency version conflicts in 4.0

This will help fix https://github.com/canjs/canjs/issues/4041 for 4.0