Skip to content

Commit

Permalink
fix(ContextMenu): fix export ContextMenu issue. (#336)
Browse files Browse the repository at this point in the history
  • Loading branch information
jaywcjlove committed Nov 8, 2023
1 parent 38c97cc commit 0878d9c
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions packages/context-menu/src/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,9 @@ const ContextMenuCompound = React.forwardRef<ContextMenuProps, ContextMenuProps>
type CompoundedComponent = typeof ContextMenuCompound & {
Item: typeof Item;
};
(ContextMenuCompound as CompoundedComponent).Item = Item;

declare const ContextMenu: CompoundedComponent;
console.log('ContextMenuCompound:', ContextMenuCompound);

export default ContextMenu;
export const ContextMenu: CompoundedComponent = ContextMenuCompound as unknown as CompoundedComponent;

ContextMenu.Item = Item;

1 comment on commit 0878d9c

@vercel
Copy link

@vercel vercel bot commented on 0878d9c Nov 8, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Successfully deployed to the following URLs:

react-amap – ./

react-amap-398188662.vercel.app
react-amap-one.vercel.app
react-amap-git-master-398188662.vercel.app

Please sign in to comment.