I'm trying to uyse synfcution.ej2.blazor 17.2.0.50-beta, the latest one on nuget, and the latest version of .net core 3.
Every chart example I find in the documentation does not render a chart. Am I missing something? Do these charts work?
I make a fresh example with the latest blazor template from microsoft, copy and paste this into my home page:
@page "/"
@using Syncfusion.EJ2.Blazor.Charts
<EjsChart Width="60%">
<ChartPrimaryXAxis ValueType="Syncfusion.EJ2.Blazor.Charts.ValueType.Category"></ChartPrimaryXAxis>
<ChartSeriesCollection>
<ChartSeries DataSource="@MedalDetails" XName="X" YName="YValue" ColumnSpacing="0.2" ColumnWidth="0.7" Type="ChartSeriesType.Bar">
</ChartSeries>
<ChartSeries DataSource="@MedalDetails" XName="X" YName="YValue1" ColumnSpacing="0.2" ColumnWidth="0.2" Type="ChartSeriesType.Bar">
</ChartSeries>
</ChartSeriesCollection>
</EjsChart>
@code{
public class ChartData
{
public string X;
public double YValue;
public double YValue1;
}
public List<ChartData> MedalDetails = new List<ChartData>
{
new ChartData { X= "USA", YValue= 46, YValue1=56 },
new ChartData { X= "GBR", YValue= 27, YValue1=17 },
new ChartData { X= "CHN", YValue= 26, YValue1=36 },
new ChartData { X= "UK", YValue= 56, YValue1=16 },
new ChartData { X= "AUS", YValue= 12, YValue1=46 },
new ChartData { X= "IND", YValue= 26, YValue1=16 },
new ChartData { X= "DEN", YValue= 26, YValue1=12 },
new ChartData { X= "MEX", YValue= 34, YValue1=32},
};
}
And nothing is on the screen, and the HTML output is just this:
<div id="chartsxmuk2il11ma" class="e-blazor-hidden"></div>
with nothing inside the div.