feat(api): create base api using ky

This commit is contained in:
Ilia Mashkov
2026-03-16 18:30:49 +03:00
parent 3214fe716d
commit 5acb326c03
3 changed files with 10 additions and 0 deletions

View File

@@ -0,0 +1,2 @@
export const BASE_URL =
import.meta.env.VITE_API_BASE_URL || "https://localhost:3001";

View File

@@ -0,0 +1,6 @@
import ky from "ky";
import { BASE_URL } from "./endpoint";
export const api = ky.create({
prefixUrl: BASE_URL,
});

View File

@@ -0,0 +1,2 @@
export * from "./api/endpoint";
export * from "./api/httpClient";