slider.on('drag', function() {
doSomething();
});
<div id ="canvas_0" class="jxgbox" style="width:100%; height:400px;"></div>
<script>
var canvas0 = JXG.JSXGraph.initBoard('canvas_0', {"boundingbox":[-10,10,10,-10], "axis":true});
var slider1 = canvas0.create('slider',[[-4, 2],[4,2],[-5,1,5]],{name:'a'});
slider1.on('move', function() {
alert("in");
});
slider1.startAnimation(1, 20);
</script>
var slider1 = canvas0.create('slider',[[-4, 2],[4,2],[-5,1,5]],{name:'a'});
slider1.coords.on('update', function() {
alert("in");
});
slider1.startAnimation(1, 20);
slider1.on('up', function() {
alert("in");
});
slider1.on('drag', function() {
value1 += 1;
num1.innerHTML = value1;
});