Add baseUrl and other assets

This commit is contained in:
Andrew Trieu
2023-07-23 12:15:34 +03:00
parent 6084131438
commit cd8c4611b6
14 changed files with 51 additions and 71 deletions

View File

@@ -1,5 +1,7 @@
import { Box } from "@mui/material";
const baseUrl = process.env.REACT_APP_BASE_URL;
const ProfilePhoto = ({ image, size = "60px" }) => {
return (
<Box width={size} height={size}>
@@ -11,7 +13,7 @@ const ProfilePhoto = ({ image, size = "60px" }) => {
width={size}
height={size}
alt="profile"
src={`http://localhost:3001/assets/${image}`}
src={`${baseUrl}/assets/${image}`}
/>
</Box>
);