check json format
This commit is contained in:
@@ -21,6 +21,8 @@ export async function post(path, body) {
|
||||
body: JSON.stringify(body)
|
||||
});
|
||||
|
||||
console.log('Data from API:', res);
|
||||
|
||||
if (res.status === 200) {
|
||||
const data = await res.json();
|
||||
console.log("Received post:", data);
|
||||
|
||||
Reference in New Issue
Block a user