Skip to main content

<Triangle />

import {ShapeSeeAlso, ShapeOptions} from "../../components/shapes/shapes-info"

Part of the @remotion/shapes package.

Renders an SVG element containing a triangle with same length on all sides.

Explorer

Example

src/Triangle.tsx
tsx
import { Triangle } from "@remotion/shapes";
import { AbsoluteFill } from "remotion";
 
export const MyComposition = () => {
return (
<AbsoluteFill
style={{
backgroundColor: "white",
justifyContent: "center",
alignItems: "center",
}}
>
<Triangle length={100} fill="red" direction="left" />
</AbsoluteFill>
);
};
src/Triangle.tsx
tsx
import { Triangle } from "@remotion/shapes";
import { AbsoluteFill } from "remotion";
 
export const MyComposition = () => {
return (
<AbsoluteFill
style={{
backgroundColor: "white",
justifyContent: "center",
alignItems: "center",
}}
>
<Triangle length={100} fill="red" direction="left" />
</AbsoluteFill>
);
};

Props

See also