Spaces:
Sleeping
Sleeping
Download frontend/src/api/client.ts from DAG-UPB/HeatTransPlan: direct link, hf CLI and curl.
- Browser
- Download file 323 Bytes
-
https://huggingface.co/spaces/DAG-UPB/HeatTransPlan/resolve/main/frontend/src/api/client.ts
- Command line
-
hf download hf://spaces/DAG-UPB/HeatTransPlan/frontend/src/api/client.ts
-
curl -L -o client.ts https://huggingface.co/spaces/DAG-UPB/HeatTransPlan/resolve/main/frontend/src/api/client.ts
323 Bytes
| import axios from 'axios'; | |
| const API_BASE = import.meta.env.VITE_API_BASE || ''; | |
| const API_KEY = import.meta.env.VITE_API_KEY || ''; | |
| const client = axios.create({ | |
| baseURL: API_BASE, | |
| headers: { | |
| 'Content-Type': 'application/json', | |
| ...(API_KEY ? { 'X-API-Key': API_KEY } : {}), | |
| }, | |
| }); | |
| export default client; | |