angular2-highcharts icon indicating copy to clipboard operation
angular2-highcharts copied to clipboard

how to use require('highcharts-more'). for some feature like series type: 'arearange'

Open dice2019 opened this issue 7 years ago • 3 comments

dice2019 avatar Oct 30 '17 08:10 dice2019

I added the ability to use highcharts-more and solid gauges by adding the following code to my module

import {ChartModule, HIGHCHARTS_MODULES} from 'angular-highcharts';

// this is how you include the // "extra" highchart advanced features import Highcharts from 'highcharts/highcharts-more.src.js'; import SolidGauge from 'highcharts/modules/solid-gauge.src.js';

export function highchartsModules() { // apply Highcharts Modules to this array return [Highcharts, SolidGauge];

@NgModule({ declarations: [ AppComponent, ], imports: [ChartModule,], })

burkeallen avatar Dec 06 '17 14:12 burkeallen

For me this works:

`//File: app.module.ts import { ChartModule } from 'angular2-highcharts'; import { HighchartsStatic } from 'angular2-highcharts/dist/HighchartsService';

export function highchartsFactory() { const hc = require('highcharts/highstock'); const dd = require('highcharts/modules/exporting'); dd(hc); return hc; }

//Section: Imports imports:[ChartModule],

//Section: Providers providers:[ { provide: HighchartsStatic, useFactory: highchartsFactory } ]`

AbdulRayhman avatar Feb 28 '18 10:02 AbdulRayhman

i have this problem too and i cant create gauge chart in my project, how can i solve this problem

more explanation about my problem is https://github.com/gevgeny/angular2-highcharts/issues/260

raha1923 avatar Mar 10 '18 11:03 raha1923