1.1.13 • Published 2 years ago

react-control-lib v1.1.13

Weekly downloads
-
License
MIT
Repository
-
Last release
2 years ago

react-control-lib

Seamless & fully customizable bar chart for React.The result of bar chart is already sorted in descending order so you don't need to write extra code for that purpose.

Quick Start

npm install --save react-control-lib
import "react-control-lib";

You should call the web component directly into your code with necessary parameters to plot the chart. All the parameters should be pass as string type since its a web component.

<racebar-chart />

Usage

Passing props.

You will need to pass your own props to the racebar-chart webcomponent. | Prop | Type | Required |Explanation | | ----------------- | ------- | ------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | | data | JSONArray | Yes | An array of objects with keys being the data for the chart . Ex- data=[{ mnth: "2020-08", cnt: "2133435", name: "Test",}]| | config | Object | Yes | An object containing keys that are in present in the array objects of the data attribute. timelinekey: the property on which timeline will be constructed. value: the property to be used to plot the data on the x-axis. label: the property to appear on labels of the bars in the chart | | detectOutliers | Boolean | No | A boolean attribute to detect and set max range to handle the scenario . Default maxRange: 6000 | | maxRange | Integer | No | A number to give the maxRange to limit the bars to plot the outliers. Default: 6000 | | top_n | Integer | No | The total numbers of entries to be displayed in the chart .Default: 12 | | intervalDuration | Integer |No | Waiting time between intervals in the timeLine (in ms). Default: 1000 | | dimensions | Object | No | An object that contains the width and height of the container .Default {width: window.innerwidth, height : 400 } |

Usage with parameters in HTML

<racebar-chart
  data='[{mnth:"2020-10-11", cnt :"234354", name:"Test name"}]'
  config='{"timelinekey":"mnth","value":"cnt","label":"name"}'
/>

Usage with parameters in React

<racebar-chart
  data={JSON.stringify(data)}
  config={JSON.stringify({
    timelinekey: "mnth",
    value: "cnt",
    label: "name",
  })}
  //optional parameters
  detectOutliers={"true"}
  dimensions={JSON.stringify({ width: 900, height: 500 })}
/>
1.1.13

2 years ago

1.1.12

2 years ago

1.1.11

2 years ago

1.1.10

2 years ago

1.1.9

2 years ago

1.1.8

2 years ago

1.1.7

2 years ago

1.1.6

2 years ago

1.1.5

2 years ago

1.1.4

2 years ago

1.1.3

2 years ago

1.1.2

2 years ago

1.1.1

2 years ago

1.1.0

2 years ago

1.0.69

2 years ago

1.0.68

2 years ago

1.0.67

2 years ago

1.0.66

2 years ago

1.0.65

2 years ago

1.0.64

2 years ago

1.0.63

2 years ago

1.0.62

2 years ago

1.0.61

2 years ago

1.0.60

2 years ago

1.0.59

2 years ago

1.0.58

2 years ago

1.0.57

2 years ago

1.0.56

2 years ago

1.0.55

2 years ago

1.0.54

2 years ago

1.0.53

2 years ago

1.0.52

2 years ago

1.0.51

2 years ago

1.0.50

2 years ago

1.0.49

2 years ago

1.0.48

2 years ago

1.0.47

2 years ago

1.0.46

2 years ago

1.0.45

2 years ago

1.0.44

2 years ago

1.0.43

2 years ago

1.0.42

2 years ago

1.0.41

2 years ago

1.0.40

2 years ago

1.0.39

2 years ago

1.0.38

2 years ago

1.0.37

2 years ago

1.0.36

2 years ago

1.0.35

2 years ago

1.0.34

2 years ago

1.0.33

2 years ago

1.0.32

2 years ago

1.0.31

2 years ago

1.0.30

2 years ago

1.0.29

2 years ago

1.0.28

2 years ago

1.0.27

2 years ago

1.0.26

2 years ago

1.0.25

2 years ago

1.0.24

2 years ago

1.0.23

2 years ago

1.0.22

2 years ago

1.0.21

2 years ago

1.0.20

2 years ago

1.0.19

2 years ago

1.0.18

2 years ago

1.0.17

2 years ago

1.0.16

2 years ago

1.0.15

2 years ago

1.0.14

2 years ago

1.0.13

2 years ago

1.0.12

2 years ago

1.0.11

2 years ago

1.0.10

2 years ago

1.0.9

2 years ago

1.0.8

2 years ago

1.0.7

2 years ago

1.0.6

2 years ago

1.0.5

2 years ago

1.0.4

2 years ago

1.0.3

2 years ago

1.0.2

2 years ago

1.0.1

2 years ago

1.0.0

2 years ago