Rectangles
A rectangle is a kind of Shape.
A Shape can be used to build rectangles, circles, paths, and more.
Below, we create a Shape that is a solid purple rectangle with a size of height: 80 and width: 120 and position it in the upper left of the screen. The center of this rectangle will be at { x: 80, y: 90 }.
Loading...
Explore:
- Add an outline to the shape by specifying its
strokeColorandlineWidth. - Make an empty shape by setting
fillColortoWebColors.Transparent. - Add rounded corners with the
cornerRadiusproperty.