javascriptvue.jshighchartsexportoffline-mode

Try to offline exporting to Highcharts


I want to make offline exporting with highcharts. Here is my code

import {Chart} from 'highcharts-vue'
import Highcharts from 'highcharts'
import offlineExporting from "highcharts/modules/offline-exporting"
offlineExporting(Highcharts)

I tried to use exporting.js and offline-exporting.js together and it worked. Is this solution of the problem? If it'not, is there any another solution?


Solution

  • To use the offline-exporting module you need to also import exporting module.

    Additionally, you can disable the fallbackToExportServer property so that the export will never use Highcharts export server.

    exporting: {
        ...,
        fallbackToExportServer: false
    },
    

    API:

    fallbackToExportServer: boolean

    Whether or not to fall back to the export server if the offline-exporting module is unable to export the chart on the client side.

    ...

    Live demo: https://jsfiddle.net/BlackLabel/92dbwLgx/

    API Reference: https://api.highcharts.com/highcharts/exporting.fallbackToExportServer

    Docs: https://www.highcharts.com/docs/export-module/client-side-export