diff --git a/packages/react-resizable-panels/src/Panel.ts b/packages/react-resizable-panels/src/Panel.ts index 26dd1821c..3c33b2295 100644 --- a/packages/react-resizable-panels/src/Panel.ts +++ b/packages/react-resizable-panels/src/Panel.ts @@ -195,12 +195,6 @@ export const Panel = forwardRef( createElement(PanelWithForwardedRef, { ...props, forwardedRef: ref }) ); -// Workaround for Parcel scope hoisting (which renames objects/functions). -// Casting to :any is required to avoid corrupting the generated TypeScript types. -// See github.com/parcel-bundler/parcel/issues/8724 -(PanelWithForwardedRef as any).displayName = "Panel"; -(Panel as any).displayName = "forwardRef(Panel)"; - // HACK function parseSizeFromStyle(style: CSSProperties): number { const { flexGrow } = style; diff --git a/packages/react-resizable-panels/src/PanelContexts.ts b/packages/react-resizable-panels/src/PanelContexts.ts index b79dab6c5..90b47fd91 100644 --- a/packages/react-resizable-panels/src/PanelContexts.ts +++ b/packages/react-resizable-panels/src/PanelContexts.ts @@ -16,8 +16,3 @@ export const PanelGroupContext = createContext<{ stopDragging: () => void; unregisterPanel: (id: string) => void; } | null>(null); - -// Workaround for Parcel scope hoisting (which renames objects/functions). -// Casting to :any is required to avoid corrupting the generated TypeScript types. -// See github.com/parcel-bundler/parcel/issues/8724 -(PanelGroupContext as any).displayName = "PanelGroupContext"; diff --git a/packages/react-resizable-panels/src/PanelGroup.ts b/packages/react-resizable-panels/src/PanelGroup.ts index 34d51012b..ea055556f 100644 --- a/packages/react-resizable-panels/src/PanelGroup.ts +++ b/packages/react-resizable-panels/src/PanelGroup.ts @@ -767,9 +767,3 @@ export const PanelGroup = forwardRef< >((props: PanelGroupProps, ref: ForwardedRef) => createElement(PanelGroupWithForwardedRef, { ...props, forwardedRef: ref }) ); - -// Workaround for Parcel scope hoisting (which renames objects/functions). -// Casting to :any is required to avoid corrupting the generated TypeScript types. -// See github.com/parcel-bundler/parcel/issues/8724 -(PanelGroupWithForwardedRef as any).displayName = "PanelGroup"; -(PanelGroup as any).displayName = "forwardRef(PanelGroup)"; diff --git a/packages/react-resizable-panels/src/PanelResizeHandle.ts b/packages/react-resizable-panels/src/PanelResizeHandle.ts index e08cdee82..ea411c4d7 100644 --- a/packages/react-resizable-panels/src/PanelResizeHandle.ts +++ b/packages/react-resizable-panels/src/PanelResizeHandle.ts @@ -189,8 +189,3 @@ export function PanelResizeHandle({ tabIndex: 0, }); } - -// Workaround for Parcel scope hoisting (which renames objects/functions). -// Casting to :any is required to avoid corrupting the generated TypeScript types. -// See github.com/parcel-bundler/parcel/issues/8724 -(PanelResizeHandle as any).displayName = "PanelResizeHandle";