Skip to content

Commit

Permalink
perf(overview): shrink the data size every minute, closes #234
Browse files Browse the repository at this point in the history
  • Loading branch information
kunish committed Sep 19, 2023
1 parent 4cc5eeb commit e0766fc
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/pages/Overview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -42,8 +42,8 @@ export default () => {
setMemories((memo) => memo.slice(-CHART_MAX_XAXIS))
})
},
// we shrink the chart data array size down every 10 minutes to prevent memory leaks
10 * 60 * 1000,
// we shrink the chart data array size down every minute to prevent memory leaks
60 * 1000,
setInterval,
)

Expand Down

0 comments on commit e0766fc

Please sign in to comment.