How to use the victory-chart/src.VictoryArea.defaultProps function in victory-chart

To help you get started, we’ve selected a few victory-chart examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github FormidableLabs / victory-chart-native / lib / components / victory-area.js View on Github external
import React from "react";
import { Dimensions, Platform } from "react-native";
import { VictoryLabel, VictoryContainer, Area, VictoryClipContainer } from "victory-core-native";
import { VictoryArea } from "victory-chart/src";

export default class extends VictoryArea {
  static defaultProps = {
    ...VictoryArea.defaultProps,
    dataComponent: <area>,
    labelComponent: ,
    containerComponent: ,
    groupComponent: ,
    width: Dimensions.get("window").width
  }

  shouldAnimate() {
    return (Platform.OS === "android") ? false : Boolean(this.props.animate);
  }
}