Use browserfiy'es watchify to watch multiple files

1.7k views Asked by At

I want to watch and output as following on Windows and Linux:

watchify ./src/login/login.js -o ./public/js/login.js -v && watchify ./src/unlock/unlock.js -o ./public/js/unlock.js -v && watchify ./src/admin/admin.js -o ./public/js/admin.js -v

Why in ./public/js directory I get just 1 file: dashboard.js instead of all of them?

1

There are 1 answers

0
marcel On

add start before each watchify command to open it into a separate window.

start watchify ./src/login/login.js -o ./public/js/login.js -v && start watchify ./src/unlock/unlock.js -o ./public/js/unlock.js -v && start watchify ./src/admin/admin.js -o ./public/js/admin.js -v