Skip to content

Commit

Permalink
public url
Browse files Browse the repository at this point in the history
  • Loading branch information
MeetMichal committed Jan 7, 2024
1 parent 9d6ff11 commit 189dc57
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion React/src/services/CsvUtils.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ const csvTextFromUrl = async (url: string): Promise<string> => {
};

export const getData = async <T>(url: string): Promise<T[]> => {
const csvText: string = await csvTextFromUrl(url);
const csvText: string = await csvTextFromUrl(process.env.PUBLIC_URL+url);
const { data } = Papa.parse(csvText, { header: true, skipEmptyLines: true, dynamicTyping:true});
return data as T[];
};
2 changes: 1 addition & 1 deletion React/src/shared/AboutDeBank.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export default function AboutNett() {
return (
<Card square elevation={0} sx={{backgroundColor: "grey.100", border:1, borderColor: 'grey.400' }} >
<CardHeader
avatar={<Avatar src="/Debank.png"/>}
avatar={<Avatar src={process.env.PUBLIC_URL+"/Debank.png"}/>}
title="DeBank"
titleTypographyProps={{variant:"h5"}}
/>
Expand Down
2 changes: 1 addition & 1 deletion React/src/shared/AboutMichal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export default function AboutMichal() {
return (
<Card square elevation={0} sx={{backgroundColor: "grey.100", border:1, borderColor: 'grey.400' }} >
<CardHeader
avatar={<Avatar src="/Michal.png"/>}
avatar={<Avatar src={process.env.PUBLIC_URL+"/Michal.png"}/>}
title="Michal"
titleTypographyProps={{variant:"h5"}}
/>
Expand Down
2 changes: 1 addition & 1 deletion React/src/shared/AboutNett.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ export default function AboutNett() {
return (
<Card square elevation={0} sx={{backgroundColor: "grey.100", border:1, borderColor: 'grey.400' }} >
<CardHeader
avatar={<Avatar src="/Nett.png"/>}
avatar={<Avatar src={process.env.PUBLIC_URL+"/Nett.png"}/>}
title="nett"
titleTypographyProps={{variant:"h5"}}
/>
Expand Down

0 comments on commit 189dc57

Please sign in to comment.