Loading source
Pulling the file list, source metadata, and syntax-aware rendering for this listing.
Source from repo
Apply 62 React and Next.js performance optimization rules from Vercel Engineering
Files
Skill
Size
Entrypoint
Format
Open file
Syntax-highlighted preview of this file as included in the skill package.
rules/rendering-svg-precision.md
1---2title: Optimize SVG Precision3impact: LOW4impactDescription: reduces file size5tags: rendering, svg, optimization, svgo6---78## Optimize SVG Precision910Reduce SVG coordinate precision to decrease file size. The optimal precision depends on the viewBox size, but in general reducing precision should be considered.1112**Incorrect (excessive precision):**1314```svg15<path d="M 10.293847 20.847362 L 30.938472 40.192837" />16```1718**Correct (1 decimal place):**1920```svg21<path d="M 10.3 20.8 L 30.9 40.2" />22```2324**Automate with SVGO:**2526```bash27npx svgo --precision=1 --multipass icon.svg28```29