Find the places a stylesheet stopped using the design system and started repeating it.
This walkthrough uses the tool's public README and checked-in example files. Run the command from a repository checkout with Node.js 22+; inspect the source before using it on your own files.
Run the checked-in example
# Clean: every governed declaration reads the token it means.
node bin/design-token-drift-auditor.mjs \
--tokens examples/tokens.json \
--config examples/config.json \
--root . \
examples/styles/clean.css
# -> "7 of 7 governed declaration(s) ... status pass." exit 0
# Drift: literals where a token already says the same thing.
node bin/design-token-drift-auditor.mjs \
--tokens examples/tokens.json \
--config examples/config.json \
--root . \
examples/styles/drift.css
# -> hardcoded-value x4, value-off-scale, unknown-token-reference exit 1
# Unknown: a computed value this tool does not evaluate.
node bin/design-token-drift-auditor.mjs \
--tokens examples/tokens.json \
--config examples/config.json \
--root . \
examples/styles/computed.css
# -> value-undetermined, status incomplete exit 2Read the result
Add --json to put the machine-readable report on stdout instead of the human summary, and --out report.json to write that report to a file as well.
Where this check stops
Every bound is enforced where it can be exceeded — never a silent truncation and never a pass. Override any of them under limits in the configuration; an unknown limit name is refused.
Before adapting the command to your own workflow, review the accepted inputs, exit codes and safety boundaries in the README.
Compiled with AI assistance from checked-in public documentation and example scripts. Run the example and review the repository's current documentation before relying on its result.