mirror of
https://github.com/LiuYuYang01/ThriveX-Blog.git
synced 2026-06-04 11:49:33 +08:00
完成目录级别样式
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
const url = "http://localhost:9999/api"
|
||||
|
||||
export default async <T>(api: string) => {
|
||||
const res = await fetch(`${url}${api}`)
|
||||
export default async <T>(api: string, data?: any) => {
|
||||
const res = await fetch(`${url}${api}`, data)
|
||||
return res.json() as Promise<Response<T>>;
|
||||
}
|
||||
Reference in New Issue
Block a user