0

I am trying to install web pack with browserify with this:

browserify main.js > bundle.js 

following these instructions: https://github.com/petehunt/webpack-howto

Terminal keeps showing:

browserify: command not found 

even after running

npm install -g browserify 

Tried using solutions from Cannot find module 'browserify' and Browserify command not found.

Here's the console window:

https://gist.github.com/robojukie/b6ca2443f02511d05f372eefc132e3a0

How can I figure out what is wrong and how to fix it?

4 Answers 4

1

A better answer is here. To quote:

Make sure that npm config get prefix/bin is in your $PATH.

Sign up to request clarification or add additional context in comments.

Comments

0

Try this:

node_modules/.bin/browserify main.js > bundle.js 

Comments

0

If you installed NPM with Brew test this

brew uninstall npm brew install npm 

Comments

0

It is an old post but I believe people are still facing the same problem like me, so this was my solution:

<your project folder>/node_modules/browserify/bin/cmd.js main.js -o bundle.js 

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.