changed .env path
This commit is contained in:
parent
6d2f313eb3
commit
353a9c4981
2
.env
2
.env
@ -1 +1 @@
|
||||
REACT_APP_API_URL=http://localhost:8000
|
||||
REACT_APP_API_URL=https://dmitriy.icu:433
|
@ -23,7 +23,7 @@ const Gallery = props => {
|
||||
useEffect( () => {
|
||||
const fetchData = async () => {
|
||||
try {
|
||||
const res = await fetch(`${process.env.REACT_APP_API_URL}/?size=${size}&page=${currentPage}`);
|
||||
const res = await fetch(`${process.env.REACT_APP_API_URL}/api/list/?size=${size}&page=${currentPage}`);
|
||||
|
||||
if (!res.ok) {
|
||||
throw Error(res.statusText);
|
||||
|
@ -4,7 +4,7 @@ import './GalleryItem.scss';
|
||||
|
||||
const GalleryItem = props => {
|
||||
const [showViewBox, setShowViewbox] = useState(false);
|
||||
const src = 'http://localhost:8000/' + props.src;
|
||||
const src = process.env.REACT_APP_API_URL + '/' + props.src;
|
||||
|
||||
return (
|
||||
<div className="galleryItem" >
|
||||
|
Loading…
x
Reference in New Issue
Block a user