Skip to main content
100%

Pitch

✓ Published1🌍 Public
MMihir Sawant
Last edited Nov 8, 2018
Created on Oct 5, 2018

This example draws a soccer pitch using D3.js version 5, with SVG rendering. It constructs the field markings—including the halfway circle, corner arcs, penalty area, and six-yard box—by combining D3’s `arc()` generator for curved paths and appended `rect` and `line` elements for straight boundaries. The layout uses hardcoded dimensions scaled by a factor of six, and all shapes are filled with white strokes atop a green background, creating a static, schematic visualization.

AI-generated description
MIT Licensed

Similar vizzes