Skip to content

Commit bbc3cf0

Browse files
committed
2 parents 98227ba + 0bdd3a4 commit bbc3cf0

File tree

1 file changed

+29
-5
lines changed

1 file changed

+29
-5
lines changed

README.md

Lines changed: 29 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,10 @@
11
![.NET Core](https://github.com/joadan/Blazor-ApexCharts/workflows/.NET%20Core/badge.svg?branch=master)
22

33
# Blazor-ApexCharts
4-
A wrapper for ApexCharts.js.
4+
A blazor wrapper for [ApexCharts.js](https://apexcharts.com/)
5+
## [Demo](https://joadan.github.io/Blazor-ApexCharts/basic-charts)
56

6-
View it in action [here](https://joadan.github.io/Blazor-ApexCharts/basic-charts)
7-
8-
**Please note: Not production ready.**
7+
**Please note: Not (yet) production ready.**
98

109

1110
## Installation
@@ -31,7 +30,7 @@ Add a reference to `Blazor-ApexCharts` in your `_Imports.razor`
3130
```csharp
3231
@using ApexCharts;
3332
```
34-
### Basic Pie Chart
33+
### Basic Chart
3534
```html
3635
<ApexChart TItem="Order" Title="Orders Net Value By Type" ChartType="ChartType.Pie">
3736
<ApexSeries TItem="Order"
@@ -45,6 +44,31 @@ Add a reference to `Blazor-ApexCharts` in your `_Imports.razor`
4544

4645
<img src="BasicPieChart.png" width="500">
4746

47+
### Chart Options
48+
Apex Chart options is available in the ApexChartOptions class that can be passed to the chart.
49+
Below is an example to show labels for a donut chart. More info in Apex documentation [ApexCharts Docs](https://apexcharts.com/docs/options/)
50+
51+
```csharp
52+
private ApexChartOptions<Order> GetChartOptions()
53+
{
54+
var options = new ApexChartOptions<Order>
55+
{
56+
PlotOptions = new PlotOptions
57+
{
58+
Pie = new PlotOptionsPie
59+
{
60+
Donut = new PlotOptionsDonut
61+
{
62+
Labels = new DonutLabels { Show = true }
63+
}
64+
}
65+
}
66+
};
67+
68+
return options;
69+
}
70+
```
71+
4872

4973
**Order Class**
5074
```csharp

0 commit comments

Comments
 (0)