Skip to content

Commit

Permalink
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add return type to withBoundingRects
Browse files Browse the repository at this point in the history
darthmaim committed Dec 16, 2024
1 parent 1deaa24 commit 5cbe4d6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/visx-bounds/src/enhancers/withBoundingRects.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* eslint react/no-did-mount-set-state: 0, react/no-find-dom-node: 0 */
import React from 'react';
import React, { ComponentClass } from 'react';
import ReactDOM from 'react-dom';

const emptyRect = {
@@ -29,7 +29,7 @@ export type WithBoundingRectsProps = {

export default function withBoundingRects<Props extends object = {}>(
BaseComponent: React.ComponentType<Props>,
) {
): ComponentClass<Props> {
return class WrappedComponent extends React.PureComponent<Props> {
static displayName = `withBoundingRects(${BaseComponent.displayName || ''})`;
node: HTMLElement | undefined | null;

0 comments on commit 5cbe4d6

Please sign in to comment.