Fix invalid reference to formatMonth in ViewBest

This commit is contained in:
Brandon Presley 2022-11-12 15:24:34 +13:00
parent c51bfbd852
commit 730a736585
1 changed files with 3 additions and 1 deletions

View File

@ -103,7 +103,9 @@ export default function ViewBest() {
yData={weights.map(set => set.weight)}
yFormat={value => `${value}${weights[0].unit}`}
xData={weights}
xFormat={(_value, index) => formatMonth(weights[index].created!)}
xFormat={(_value, index) =>
format(new Date(weights[index].created), 'D/M')
}
/>
)}
</View>