feat(api): create base api using ky
This commit is contained in:
@@ -0,0 +1,2 @@
|
|||||||
|
export const BASE_URL =
|
||||||
|
import.meta.env.VITE_API_BASE_URL || "https://localhost:3001";
|
||||||
@@ -0,0 +1,6 @@
|
|||||||
|
import ky from "ky";
|
||||||
|
import { BASE_URL } from "./endpoint";
|
||||||
|
|
||||||
|
export const api = ky.create({
|
||||||
|
prefixUrl: BASE_URL,
|
||||||
|
});
|
||||||
@@ -0,0 +1,2 @@
|
|||||||
|
export * from "./api/endpoint";
|
||||||
|
export * from "./api/httpClient";
|
||||||
Reference in New Issue
Block a user