message
: The default message that will be shown for the check in the CLI and Commonality Studiovalidate
: A function that returns a boolean or a promise that resolves to a boolean. This function is used to determine if the check passes or fails.build
script with a value of tsc --build
in it’s package.json
.
suggestion
property is also useful for showing how a fix function will modify a file.
The diff function will return a pretty printed string where unique properties and values in the second argument appear in red and are prefixed with +
.”
The following output will be shown if the check fails:
true
.
Commonality provides utilities like json, and text to make it easy to read and write files within fix functions.