MAINT Use prettier to format javascript. 
#!/bin/bash
FILES=$(git diff --cached --name-only *.c *.h *.js)
if [ -z "$FILES" ]; then
    exit 0
fi

# Change files, stage changes
clang-format-6.0 -verbose -i $FILES
git add $FILES

#!/bin/bash
FILES=$(git diff --cached --name-only *.c *.h)
if [ -n "$FILES" ]; then
    echo hi
    # Change files, stage changes
    clang-format-6.0 -verbose -i $FILES
    git add $FILES
fi

FILES=$(git diff --cached --name-only *.js)
if [ -n "$FILES" ]; then
    # Change files, stage changes
    ./node_modules/.bin/prettier --write $FILES
    git add $FILES
fi
