@visx/clip-path

React utilities for defining <clipPath> SVG elements, with or without data, to be clip masks for other SVG elements by using their clip-path property.

Installation

npm install --save @visx/clip-path

APIs

#<ClipPath />

# idstringrequired

Unique id for the clipPath.

# childrenReactNode

clipPath children.

#<CircleClipPath />

# idstringrequired

Unique id for the clipPath.

# cxReactText

x position of the center of the ClipPath circle.

# cyReactText

y position of the center of the ClipPath circle.

# rReactText

radius of the ClipPath circle.

#<RectClipPath />

# idstringrequired

Unique id for the clipPath.

# heightReactText

height of the ClipPath rect.

Default 1

# widthReactText

width of the ClipPath rect.

Default 1

# xReactText

x position of the ClipPath rect.

Default 0

# yReactText

y position of the ClipPath rect.

Default 0