conic/angular/sweep gradient view
npm install expo-conic-gradient``sh`
yarn add expo-conic-gradient
`tsx
import { ConicGradientView } from "expo-conic-gradient";
export default () => {
return (
/>
);
};
`
`tsx`
import { ConicGradientView } from "expo-conic-gradient";
| name | type | default |
| --- | --- | --- |
| colors | string[] | |
| locations | number[] | [] |
| center | [x: number, y: number] | [0.5, 0.5] |
| angle | number | 0 |
An array of colors representing the gradient stops. A minimum of two colors is required.
An array of numbers in 0 - 1 range, matching the length of the colors` array. Each number specifies the stop of the corresponding color. If omitted, the colors will be evenly spaced throughout the gradient.
An array of two numbers specifying the x and y coordinate of the center point of the gradient.
A number that specifies the starting angle of the gradient.