Skip to content

Instantly share code, notes, and snippets.

@mattgle
Last active October 25, 2019 17:40
Show Gist options
  • Save mattgle/9841e893f3c8534fad5f0e745914e5d5 to your computer and use it in GitHub Desktop.
Save mattgle/9841e893f3c8534fad5f0e745914e5d5 to your computer and use it in GitHub Desktop.
import React from 'react';
import { View } from 'react-native';
import { VictoryPie } from 'victory-native';
import styles from './styles';
const graphicData = [{ y: 10 }, { y: 50 }, { y: 40 }];
const graphicColor = ['#388087', '#6fb3b8', '#badfe7'];
function Home() {
return (
<View style={styles.container}>
<VictoryPie
animate={{ easing: 'exp' }}
data={graphicData}
width={250}
height={250}
colorScale={graphicColor}
innerRadius={50}
/>
</View>
);
}
export default Home;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment