Dependency Management Got Awesome CommonJS and AMD Compliant dependency loader for modern web apps
Sometimes you want a Module ID to be available in more than one location. While Inject can change a module’s ID directly using
Inject.addModuleRule, this can sometimes throw off relative includes. Instead, it’s much easier to map a resolvedId to multiple locations.
These “virtual” locations behave just like a normal exports location and can be require()-ed as well.
// install jQuery into a global location Inject.addPackage('common/libs/jquery', 'jquery');
This is the resolved Module ID to compare against. It is a string.
This is the additional Module ID to save this package under. It is a string.
The family of rules Inject supports: