Highcharts is an SVG-based, multi-platform charting library that has been actively developed since 2009. It makes it easy to add interactive, mobile-optimized charts to your web and mobile projects. It features robust documentation, advanced responsiveness and industry-leading accessibility support.
In this example, we will allow the user to add a random point on the chart through a button on the browser, clicking on the button will invoke add () method to generate a random number on the chart.
Step 1: Setup the project
Step 2: Create a component SimplechartComponent
ng generate component simplechart
Add the following code in SimplechartComponent.ts
ྭWe have to import Chart from Angular-highcharts module in simplechartComponent.ts file and add the following code in simplechartComponent.html file
Step 3: Use app-simplechart selector in app.component.html file
Atlast we have to register or import the highChar module in app.module.ts file.