What problem does it solve?
This Skill prevents incorrect token amount calculations caused by wrong or hardcoded ERC20 decimals across different EVM chains.
Core Features & Use Cases
- Audit and validate decimals: Identify hardcoded decimal usage and compare configured values against on-chain decimals() results for each deployment.
- Per-chain configuration guidance: Update network/token configuration with chain-specific decimals and ensure conversions like FromWei/ToWei use the correct per-chain value.
- Safety guardrails for common failures: Use sensible fallbacks for unknown chains and add startup validation to detect mismatches before production.
Use case example: You deploy a token to Ethereum, Polygon, and BNB Chain, then your app starts showing balances that are off by orders of magnitude; use this Skill to query actual on-chain decimals and fix each chain’s configuration so all conversions and UI amounts line up.
Quick Start
Run evm-decimal-validation to audit your repo’s decimal usage, query the token contract decimals on your target chains, and update your per-chain configuration so conversions match on-chain reality.