From 94741fb25dd6c60571e78393c43355d8ddf8b64d Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Mon, 5 Nov 2018 12:46:18 +0300 Subject: AvatarLink --- vnext/src/components/Avatar.js | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'vnext/src/components') diff --git a/vnext/src/components/Avatar.js b/vnext/src/components/Avatar.js index 31d7dd34..c42a048a 100644 --- a/vnext/src/components/Avatar.js +++ b/vnext/src/components/Avatar.js @@ -4,7 +4,7 @@ import { Link } from 'react-router-dom'; import { UserType } from './Types'; -const Avatar = React.memo(function AvatarComponent(props) { +const Avatar = React.memo(props => { return (
@@ -26,6 +26,15 @@ const Avatar = React.memo(function AvatarComponent(props) { export default Avatar; +export const AvatarLink = React.memo(props => { + return ( + + {`${props.user.uname}`} + {props.user.uname} + + ); +}); + Avatar.propTypes = { user: UserType, link: PropTypes.string, -- cgit v1.2.3