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

Does angular-highcharts support universal/server side rendering

Open jpspringall opened this issue 5 years ago • 1 comments

More of question than an issue,

Just wondering if angular high-charts supports SSR?

When I try and run in SSR mode, I get the following error when trying to browse to a url: TypeError: Cannot read property 'parts/Globals.js' of undefined

I suspect it may be related to something to do with the lack of window object.

Just wondering.

Cheers

James

jpspringall avatar Aug 01 '20 03:08 jpspringall

I have answered my own question

Yes it does

You just have to do the following, in your app.server.module.ts use the following as your provider: providers: [{ provide: HIGHCHARTS_MODULES, useFactory: () => []}

Cheers

James

jpspringall avatar Aug 01 '20 05:08 jpspringall