pass in args

This commit is contained in:
Ashwin Bhat 2024-11-19 11:42:11 -08:00
commit c1a56810fb
No known key found for this signature in database

View file

@ -186,9 +186,13 @@ const App = () => {
}, [args]);
useEffect(() => {
fetch("http://localhost:3000/default-environment")
fetch("http://localhost:3000/config")
.then((response) => response.json())
.then((data) => setEnv(data))
.then((data) => {
setEnv(data.defaultEnvironment);
setCommand(data.defaultCommand);
setArgs(data.defaultArgs);
})
.catch((error) =>
console.error("Error fetching default environment:", error),
);