ant-design/components/anchor/index.tsx
vagusX 38cf5e8a75
docs: unify component export file as index.tsx (#50013)
* docs: unify component export file as index.tsx

* docs: compatible with old anchors

* chore: clean

* test: update snapshot

* fix: window env

---------

Co-authored-by: Peach <scdzwyxst@gmail.com>
2024-07-23 22:22:24 +08:00

17 lines
413 B
TypeScript

import InternalAnchor from './Anchor';
import AnchorLink from './AnchorLink';
export type { AnchorProps } from './Anchor';
export type { AnchorLinkProps } from './AnchorLink';
type InternalAnchorType = typeof InternalAnchor;
type CompoundedComponent = InternalAnchorType & {
Link: typeof AnchorLink;
};
const Anchor = InternalAnchor as CompoundedComponent;
Anchor.Link = AnchorLink;
export default Anchor;