blob: 65c3fcfcbc434a18cdb39e39210784093f8c36c3 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
|
import React from 'react';
import { User } from '../../types';
import SignInForm from './SignInForm';
import ProfileInfo from './ProfileInfo';
import Feed from "../../Components/Feed/Feed";
interface PropTypes {
setUser: (newUser: User | undefined) => void;
user: User | undefined;
}
const ProfilePage: React.FC<PropTypes> = ({ setUser, user}) => {
return (
user ? <>
<ProfileInfo id={user?._id} setUser={setUser} />
<Feed page={'Feed'}/>
</>
: <SignInForm setUser={setUser} />
);
};
export default ProfilePage;
|