add Sparkline charts to svelte

علی ذوالفقار
1401/08/28 11:09:34 (39)
use jQuery Sparklines :
https://omnipotent.net/jquery.sparkline/#s-download
usage :
< script type="text/javascript" src="jquery-1.7.2.js">< /script>
< script type="text/javascript" src="jquery.sparkline.js">< /script>
var myvalues = [10,8,5,7,4,4,1];
$('.dynamicsparkline').sparkline(myvalues);
$('.dynamicbar').sparkline(myvalues, {type: 'bar', barColor: 'green'} );
$(`#sparkline_${f.name}`).sparkline( values , {
     type : 'line' ,
     width : 80 ,
     height : 40 ,
     fillColor : fillColor ,
     lineColor : lineColor ,
     disableTooltips : true ,
     normalRangeMin : normalRangeMin ,
     normalRangeMax : normalRangeMax ,
     lineWidth : 2
    });
Back