The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

390885 (23) [Avatar] Offline
#1
On page 57, it states that add this line into package.json
./node_modules/.bin/babel js/script.jsx ?o js/script.js

But it turns out that there is no need to use relative path on my machine with OS X.
babel js/script.jsx ?o js/script.js

is enough.
Azat Mardan (41) [Avatar] Offline
#2
Good for you, but this might not be the case for others. It depends on the path to node_modules/.bin in your bash/zsh.

If you have something like this in your profile, then no need:

if [ -d "$PWD/node_modules/.bin" ]; then
PATH="$PWD/node_modules/.bin"
fi


But my full path command is more robust since it will work anywhere!

---

Azat, author of React Quickly