Spaces:
Sleeping
Sleeping
Xiao commited on
Commit ·
72de59b
1
Parent(s): 5815d8e
testing huggingface 5000 api
Browse files- src/App.js +5 -2
src/App.js
CHANGED
|
@@ -10,8 +10,11 @@ function App() {
|
|
| 10 |
};
|
| 11 |
|
| 12 |
const handleButtonClick2 = () => {
|
| 13 |
-
fetch('
|
| 14 |
-
.then((response) =>
|
|
|
|
|
|
|
|
|
|
| 15 |
.then((data) => console.log(data.message))
|
| 16 |
.catch((error) => console.error('An error occurred:', error));
|
| 17 |
};
|
|
|
|
| 10 |
};
|
| 11 |
|
| 12 |
const handleButtonClick2 = () => {
|
| 13 |
+
fetch('api/')
|
| 14 |
+
.then((response) => {
|
| 15 |
+
response.json()
|
| 16 |
+
console.log(response)
|
| 17 |
+
})
|
| 18 |
.then((data) => console.log(data.message))
|
| 19 |
.catch((error) => console.error('An error occurred:', error));
|
| 20 |
};
|