require-rootify
Require a modules within a root directory (browserify transform) with a caret symbol (^)
Install
First, you need a browserify project, ofcourse. Then, run npm install --save-dev require-rootify
and
add to your browserify config something like
{ bundle; }
Example
Before:
var path = ; // Ok, node modulevar _ = ; // Ok too, npm modulevar myComponent = ; // Oh, what is that??
After:
var path = ; // Ok, node modulevar _ = ; // Ok too, npm modulevar myComponent = ; // Yea, much better