-
Notifications
You must be signed in to change notification settings - Fork 78
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ApexChart Angular doesn't render anything #197
Comments
The problem is that you are using
|
I have same issue even when chartOptions is inside ngOnInit. I can get chart to render when I resize the page. |
Try to add this to your
Example:
and in your template, in the apex chart component tag, you could have this:
Example:
|
Thanks for that. I managed to get it firing with something similar. (I got
the ElementRef.nativeElement and fired the buildChart method, then render,
I think it ended up being). Not sure about OP but thankyou for your help.
…On Mon, 23 May 2022, 5:18 am Thiago Guimarães, ***@***.***> wrote:
I have same issue even when chartOptions is inside ngOnInit. I can get
chart to render when I resize the page.
Try to add this to your chartOptions
chart: {
height: 350,
width: '100%',
type: 'bar'
}
Example:
//Chart options
this.chartOptions = {
.....
chart: {
height: 350,
width: '100%',
type: 'bar'
},
.....
}
and in your template, in the apex chart component tag, you could have this:
[chart]="chartOptions.chart
Example:
<apx-chart [chart]="chartOptions.chart"></apx-chart>
—
Reply to this email directly, view it on GitHub
<#197 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAQEGD6A2KPXEG5IVGIBPFTVLKCCFANCNFSM5PJUWYVA>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
Any solution for this issue available? We have the same problem, only rendering after resizing |
Have you tried setting up the chart in your |
i have the same problem. Setting up the chart in the ngOnInit do not resolve the problem. In my example, i update the series and the xaxis. If i update only one of these (series or xaxis), the chart render correctly. When i want to update the series and the xaxis at the same time, it doesn't work until i resize the browser. |
Hi!
I'm trying to integrate apexchart into my webapp, but doen't render anything and no error are show in console.
I based the test in https://apexcharts.com/angular-chart-demos/line-charts/basic/
My stack
"@angular/common": "~13.0.0", "@ionic/angular": "^6.0.0", "apexcharts": "^3.33.1", "ng-apexcharts": "^1.7.0",
The steps that i make:
1º Install npm libraries
2º Add
NgApexchartsModule
toapp.module.ts
3º In a tab page
In profile.page.html
I'm make any thing wrong?? Thanks!!
The text was updated successfully, but these errors were encountered: