added event bus. working on a gateway object base class.

This commit is contained in:
2024-12-15 15:11:59 -06:00
parent fbdff25c14
commit 13b25ca7d2
12 changed files with 156 additions and 65 deletions
+3 -3
View File
@@ -13,9 +13,6 @@ export class API {
'Content-Type': 'application/json'
};
console.log(`API Request: ${method} ${url}`);
console.log(`API Body: ${JSON.stringify(data, null, 4)}`);
const response = await fetch(url, {
method,
headers,
@@ -30,6 +27,9 @@ export class API {
const body = await response.json();
// console.log(`API Request: ${method} ${url}`);
// console.log(`API Body: ${JSON.stringify(data, null, 4)}`);
// console.log('API Response:', JSON.stringify(body, null, 4));
return body;