Skip to content

Commit ec0f461

Browse files
authored
fix: menuItem should support target (#558)
1 parent ea086ee commit ec0f461

1 file changed

Lines changed: 5 additions & 1 deletion

File tree

packages/plugin-layout/src/layout/index.tsx

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,7 +112,11 @@ const BasicLayout = (props: any) => {
112112
return defaultDom;
113113
}
114114
if (menuItemProps.path && location.pathname !== menuItemProps.path) {
115-
return <Link to={menuItemProps.path}>{defaultDom}</Link>;
115+
return (
116+
<Link to={menuItemProps.path} target={menuItemProps.target}>
117+
{defaultDom}
118+
</Link>
119+
);
116120
}
117121
return defaultDom;
118122
}}

0 commit comments

Comments
 (0)