makeRect()
import {MakeShapeSeeAlso, ShapeOptions, MakeShapeReturnType} from "../../components/shapes/shapes-info"
Part of the @remotion/shapes
package.
Generates an SVG rectangle.
Example
rect.tstsx
import {makeRect } from "@remotion/shapes";const {path ,width ,height ,transformOrigin } =makeRect ({width : 100,height : 100,});console .log (path ); // M 0 0 l 100 0 l 0 100 l -100 0 Zconsole .log (width ); // 100console .log (height ); // 100console .log (transformOrigin ); // '50 50'
rect.tstsx
import {makeRect } from "@remotion/shapes";const {path ,width ,height ,transformOrigin } =makeRect ({width : 100,height : 100,});console .log (path ); // M 0 0 l 100 0 l 0 100 l -100 0 Zconsole .log (width ); // 100console .log (height ); // 100console .log (transformOrigin ); // '50 50'