MDK Logo
UI Kitreact-devkitHooks

useSubsidyFees

Aggregates raw subsidy-fee log entries into chart-ready datasets keyed by the active period type (day / week / month / year) and surfaces a summary for the m…

Aggregates raw subsidy-fee log entries into chart-ready datasets keyed by the active period type (day / week / month / year) and surfaces a summary for the matching reporting widgets. Used by `SubsidyFee`; expose to downstream apps that need to recompose the same datasets in a custom UI.

import { useSubsidyFees } from "@tetherto/mdk-react-devkit";

Signature

({ data, log, dateRange }: UseSubsidyFeesInput) => { summary: SubsidyFeeSummary; filteredLog: SubsidyFeesLogEntry[]; aggregatedData: AggregatedPeriodData[]; subsidyFeesChartData: BarChartDataResult; averageFeesChartData: BarChartDataResult;… /* see source */
Package@tetherto/mdk-react-devkit