Hi,
I’m trying to use CanvasJS with Electron, but I’m getting the bellow error:
A JavaScript error occurred in the main process
Uncaught Exception:
import CanvasJS from ‘canvasjs’;
^^^^^^
SyntaxError: Unexpected token import
In my code, I’m requiring CanvasJS as below:
var CanvasJS = require(‘canvasjs’);
Is there a workaround to solve this issue?
Best regards