
Get Professional Support for BrowserifyBrowsers don't have therequire method defined, but Node.js does. With Browserify you can write code that usesrequire in the same way that you would use it in Node.
Here is a tutorial on how to use Browserify on the command line to bundle up a simple file calledmain.js along with all of its dependencies:
var unique =require('uniq');var data =[1, 2, 2, 3, 4, 5, 5, 5, 6];console.log(unique(data));
npm install uniqbrowserifymain.js -obundle.js
<script src="bundle.js"></script>
Browserify is elegant and fast. It makes frontend development fun again! That's why we used it to build Yahoo's new HTML5 video player.-feross, developer on the Video team atYahoo.
At Mapbox we build our website and JavaScript API with Browserify. It makes the structure and modularity of our code rock.-tmcw, developer atMapbox.
Browserify does exactly what it says it does and it does it well. I'm glad it exists.-zpao, developer on theReact team at Facebook.
Browserify radically sped up builds, simplified builds and encouraged modularity.-terinjokes, developer at CloudFlare.