Skip to content

Commit

Permalink
replace ts-ignore with manual type casting
Browse files Browse the repository at this point in the history
  • Loading branch information
darnautov committed Jun 4, 2021
1 parent 9bb03df commit ef95471
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -84,8 +84,7 @@ export const HeatmapComponent: FC<HeatmapRenderProps> = ({
const xValuesFormatter = formatFactory(xAxisMeta.params);
const valueFormatter = formatFactory(valueColumn.meta.params);

// @ts-ignore
const onElementClick: ElementClickListener = (e: HeatmapElementEvent[]) => {
const onElementClick = ((e: HeatmapElementEvent[]) => {
const cell = e[0][0];
const { x, y } = cell.datum;

Expand Down Expand Up @@ -119,7 +118,7 @@ export const HeatmapComponent: FC<HeatmapRenderProps> = ({
timeFieldName,
};
onClickValue(desanitizeFilterContext(context));
};
}) as ElementClickListener;

const onBrushEnd = (e: HeatmapBrushEvent) => {
const { x, y } = e;
Expand Down

0 comments on commit ef95471

Please sign in to comment.