1

My path fills the SVG horizontally perfectly by vertically it has spacing to the top and bottom as you can see.

How can I remove that spacing and have the path fill the entire height of the SVG element?

Here is my code and a screenshot of the SVG Path. I have colored the SVG background to red so you can see the spacing issue.

enter image description here

<Svg 
  id="chart" 
  width={chartWidth} 
  height={CHART_HEIGHT}>
<Path
  d={data}
  fill='transparent'
  stroke={color}
  strokeWidth={2}></Path>
</Svg>
Hugo
  • 2,073
  • 6
  • 23
  • 46

0 Answers0