thlorenz/browserify-shim — pull request #109 by dnjohnson (2014-11-30 22:56:48+00:00)
Title: Permits exporting a string literal as a shim

I had a need for this so feel free to merge in if you think it might be useful to others. Basically just let's you shim a module as a simple string, i.e. in your config:

"browserify-shim": {
"./angular/angular-route.js": "'ngRoute'"
}

So when required:

var ngRoute = require("angular-route"); // ngRoute == 'ngRoute'

I specifically needed this so I could tie in seamlessly with Angular's module system:

angular.module("ModuleName", [ require("angular-route") ]);

But yeah, might be a limited use case.