Do this in your project.
npm install --save content-as-code
content-as-code
comes with a binary that is your primary interaction tool.
$(npm bin)/cac --help
Set the DEBUG
environment variable to the appropriate debug target. The list
of all valid debug targets can be listed in the content-as-code
git
repository:
find lib -type f -print0 \
| xargs -0 grep -oP "debug(\(.*\))" \
| awk -F ':' '{print $2;}' \
| uniq
*
stands for all debug targets.
DEBUG=* $(npm bin)/cac validate
DEBUG=tasks $(npm bin)/cac build
DEBUG=cli $(npm bin)/cac build
DEBUG=cli,tasks $(npm bin)/cac validate
Run all unit tests found in test
.
npm run test
This runs the flow type checks and the eslint syntax validation.
npm run lint
npm run build