diff --git a/src/components/timeline.tsx b/src/components/timeline.tsx index d0d290d..8db2636 100644 --- a/src/components/timeline.tsx +++ b/src/components/timeline.tsx @@ -44,11 +44,13 @@ export default function Timeline() { } }; }, []); - return ( + return tweets.length !== 0 ? ( {tweets.map((tweet) => ( ))} + ) : ( + 작성된 글이 없습니다. ); } diff --git a/src/components/user-timeline.tsx b/src/components/user-timeline.tsx index 7fd25be..25444e1 100644 --- a/src/components/user-timeline.tsx +++ b/src/components/user-timeline.tsx @@ -9,9 +9,9 @@ import { where, } from 'firebase/firestore'; import { auth, db } from '../firebase.ts'; +import ITweet from '../interfaces/ITweet.ts'; import Tweet from './tweet.tsx'; import * as S from '../styles/timeline.ts'; -import ITweet from '../interfaces/ITweet.ts'; export default function UserTimeline() { const user = auth.currentUser; @@ -47,11 +47,13 @@ export default function UserTimeline() { } }; }, []); - return ( + return tweets.length !== 0 ? ( {tweets.map((tweet) => ( ))} + ) : ( + 작성된 글이 없습니다. ); }