From 07690dab7f064b38e0604e8d16a0eff477cdbeaf Mon Sep 17 00:00:00 2001 From: "sigonasr2, Sig, Sigo" Date: Mon, 26 Jul 2021 01:06:42 +0000 Subject: [PATCH] Include dynamic choosing of BACKEND_URL based on environment variable setup. --- src/App.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/App.js b/src/App.js index a22da3b..bc8cf63 100644 --- a/src/App.js +++ b/src/App.js @@ -19,7 +19,7 @@ import TestPanel from './TestPanel'; // Dudley's Test Panel const axios = require('axios'); -const BACKEND_URL = 'https://projectdivar.com:4504'; +const BACKEND_URL = process.env.REACT_APP_BACKEND_URL||'https://projectdivar.com:4504'; //You can specify a .env file locally with REACT_APP_BACKEND_URL defining a URL to retrieve data from. function Col(p) { return
@@ -662,7 +662,7 @@ function App() { - Modal content goes here. {process.env.REACT_APP_TEST} + Modal content goes here.{BACKEND_URL}