File tree Expand file tree Collapse file tree 2 files changed +12
-2
lines changed
Expand file tree Collapse file tree 2 files changed +12
-2
lines changed Original file line number Diff line number Diff line change 1+ const { REACT_APP_HOST_ADDRESS , REACT_APP_SERVER_PORT } = process . env ;
2+
13export class HTTP {
24 private domain : string = "" ;
35
@@ -40,6 +42,8 @@ export class HTTP {
4042 }
4143}
4244
43- const instance = new HTTP ( "http://localhost:8000" ) ;
45+ const instance = new HTTP (
46+ `http://${ REACT_APP_HOST_ADDRESS } :${ REACT_APP_SERVER_PORT } `
47+ ) ;
4448
4549export default instance ;
Original file line number Diff line number Diff line change 1+ # Client port number to open this react-app.
12PORT = 3000
2- HOST_ADDRESS = " localhost" # Put the IP or host address of the computer you are using.
3+
4+ # Enter the same value as the PORT environment variable written in .server.env.
5+ REACT_APP_SERVER_PORT = 8000
6+
7+ # Put the IP or host address of the computer you are using.
8+ REACT_APP_HOST_ADDRESS = " localhost"
You can’t perform that action at this time.
0 commit comments