Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I'm trying to use the justGage (http://justgage.com/) plugin in an extension but can't get it to work.
This is my setup:
Scriptfile:
define( [ "qlik", "text!./template.html", "./js/raphael-2.1.4.min", "./js/justgage" ], function ( qlik, template ) { return { template: template, support: { snapshot: true, export: true, exportData: false }, paint: function () { return qlik.Promise.resolve(); }, controller: ['$scope', function ( $scope ) { g = new JustGage({ id: "gauge", value: 67, min: 0, max: 100, title: "Visitors" }); }] }; } );
Template:
<div qv-extension style="height: 100%; position: relative; overflow: auto;" class="ng-scope"> <div id="gauge" class="200x160px"></div> </div>
But as soon as I execute this code I get the following error message:
What am I doing wrong here?
Regards
Hello ,
You should try load the plug-in first in the define:
define( [
"./js/raphael-2.1.4.min",
"qlik",
"text!./template.html",
"./js/justgage"
]
or use raphael-amd as a dependency - https://github.com/Deep-Freeze/raphael-amd
Seems that a problem exists with that plug-in.
https://github.com/DmitryBaranovskiy/raphael/issues/524
BR,
Pedro