Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.solidscipt.zoracle.xyz/llms.txt

Use this file to discover all available pages before exploring further.

The gasdiff command builds your contracts twice — once with optimizer passes enabled and once without — compiles both outputs with solc, and prints a side-by-side bytecode size comparison. Use it whenever you change optimizer settings or add new optimizer passes and want a quick sanity check on the impact before sending the change out for review.
solidscript gasdiff <input>

Arguments

ArgumentDescription
<input>Path to the directory containing your TypeScript contract files

Examples

# Compare optimized and unoptimized bytecode sizes
npx solidscript gasdiff contracts
Run gasdiff before and after a refactor to confirm that optimizer behavior changed in the direction you expected. A larger unoptimized size with a smaller optimized size is the ideal outcome.