react-native-svg-charts
Version:
Customizable charts (Line, Bar, Area, Pie, Circle, Progress) for React Native
15 lines (12 loc) • 366 B
JavaScript
import React from 'react'
import { G } from 'react-native-svg'
const Decorator = ({ children, data, ...props }) => {
return (
<G>
{React.Children.map(children, (child) => {
return data.map((value, index) => React.cloneElement(child, { value, index, ...props }))
})}
</G>
)
}
export default Decorator