react-native-leader-line
Version:
React Native port of leader-line library for drawing arrow lines and connectors
49 lines • 1.41 kB
TypeScript
/**
* @fileoverview Memoized Path Component
* @description Performance-optimized SVG path component for LeaderLine
* @version 1.2.0
* @author Federico Garcia
*/
import React from 'react';
/**
* @interface MemoizedPathProps
* @description Props for the memoized path component
*/
export interface MemoizedPathProps {
/** SVG path data */
d: string;
/** Stroke color */
stroke?: string;
/** Stroke width */
strokeWidth?: number;
/** Fill color */
fill?: string;
/** Stroke opacity */
strokeOpacity?: number;
/** Fill opacity */
fillOpacity?: number;
/** Stroke dash array */
strokeDasharray?: string;
/** Stroke dash offset */
strokeDashoffset?: number;
/** Stroke line cap */
strokeLinecap?: 'butt' | 'round' | 'square';
/** Stroke line join */
strokeLinejoin?: 'miter' | 'round' | 'bevel';
/** Opacity */
opacity?: number;
/** Transform */
transform?: string;
/** Test ID for testing */
testID?: string;
}
/**
* @component MemoizedPath
* @description Performance-optimized SVG path component with React.memo
*
* This component is memoized with a custom comparison function to prevent
* unnecessary re-renders when path properties haven't changed significantly.
*/
declare const MemoizedPath: React.FC<MemoizedPathProps>;
export default MemoizedPath;
//# sourceMappingURL=MemoizedPath.d.ts.map