Files
cannaiq/frontend/node_modules/recharts/es6/context/legendPayloadContext.js
2025-11-28 19:45:44 -07:00

10 lines
359 B
JavaScript

import { useAppSelector } from '../state/hooks';
import { selectLegendPayload } from '../state/selectors/legendSelectors';
/**
* Use this hook in Legend, or anywhere else where you want to read the current Legend items.
* @return all Legend items ready to be rendered
*/
export function useLegendPayload() {
return useAppSelector(selectLegendPayload);
}