From f861e6a269ba9f62700776d3cd13b644a9e836d4 Mon Sep 17 00:00:00 2001 From: Armand Philippot Date: Wed, 20 Sep 2023 16:38:54 +0200 Subject: refactor: use named export for everything except pages Next expect a default export for pages so only those components should use default exports. Everything else should use named exports to reduce the number of import statements. --- src/components/organisms/widgets/social-media.tsx | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) (limited to 'src/components/organisms/widgets/social-media.tsx') diff --git a/src/components/organisms/widgets/social-media.tsx b/src/components/organisms/widgets/social-media.tsx index 1a261a9..40513f8 100644 --- a/src/components/organisms/widgets/social-media.tsx +++ b/src/components/organisms/widgets/social-media.tsx @@ -1,8 +1,6 @@ import { FC } from 'react'; -import SocialLink, { - type SocialLinkProps, -} from '../../atoms/links/social-link'; -import Widget, { type WidgetProps } from '../../molecules/layout/widget'; +import { SocialLink, type SocialLinkProps } from '../../atoms'; +import { Widget, type WidgetProps } from '../../molecules'; import styles from './social-media.module.scss'; export type Media = SocialLinkProps; @@ -16,7 +14,7 @@ export type SocialMediaProps = Pick & { * * Render a social media list with links. */ -const SocialMedia: FC = ({ media, ...props }) => { +export const SocialMedia: FC = ({ media, ...props }) => { /** * Retrieve the social media items. * @@ -37,5 +35,3 @@ const SocialMedia: FC = ({ media, ...props }) => { ); }; - -export default SocialMedia; -- cgit v1.2.3