Almost there

This commit is contained in:
Daniel Ledda
2020-11-14 16:26:46 +01:00
parent b8a3dc1c38
commit a43ed14019
2 changed files with 2 additions and 1 deletions

View File

@@ -64,6 +64,7 @@ class ClimateChart {
this.chart = new Chart(ctx, generateClimateChartConfig({}));
try {
const payload = await this.getInitialDataBlob();
console.log(payload);
this.latestSnapshot = payload.snapshots[payload.snapshots.length - 1];
this.insertSnapshots(...payload.snapshots);
setInterval(() => this.updateFromServer(), 30 * 1000);