rewritify
browserify transform that rewrites require paths.
example
;
Now you can do require('bar/x')
from anywhere.
api
rewritify([file,] opts)
opts
object can have these properties:
mapping
lets you map a name into a lookup path. You can also use this per-module or per-file basis like browser field.basedir
is used to resolve relative paths defined in mapping property, by default this isdirname
of the processed file.extensions
is an array of optional extra extensions for module lookup machinery to use when the extension has not been specified.
license
mit