isite
Version:
Create High Level Multi-Language Web Site [Fast and Easy]
45 lines (30 loc) • 929 B
HTML
<html lang="En">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<meta http-equiv="X-UA-Compatible" content="ie=edge">
<title>
Object In Array (PieSeries)
</title>
<link rel="stylesheet" href="css/style.css">
</head>
<body>
<div id="chartdiv"></div>
<script src="./js/chart-core.js"></script>
<script src="./js/charts.js"></script>
<script src="./js/chart-animated.js"></script>
<script>
// Set theme
am4core.useTheme(am4themes_animated);
// Create chart
fetch('./json/gauge.json').then(res => res.json()).then(obj => {
var chart = am4core.createFromConfig(obj, "chartdiv", am4charts.GaugeChart);
setInterval(function () {
var hand = chart.hands.getIndex(0);
hand.showValue(Math.random() * 100, 1000, am4core.ease.cubicOut);
}, 2000);
})
</script>
</body>
</html>