chore: track root project files and subrepos

This commit is contained in:
hajimi
2026-05-23 13:22:03 +08:00
parent 1624f023a2
commit 648ed678f3
1035 changed files with 154418 additions and 1 deletions
+18
View File
@@ -0,0 +1,18 @@
import { createRequest } from '~~/utils/http'
export default defineNuxtPlugin(() => {
const request = createRequest()
//@ts-ignore 添加
globalThis.$request = request
const $fetchOriginal = globalThis.$fetch
const $fetch: any = (url: string, opts?: any) => {
opts = opts ?? {}
opts.url = url
return request.request(opts, opts.requestOptions)
}
$fetch.raw = $fetchOriginal.raw
$fetch.create = $fetchOriginal.create
//@ts-ignore 重写$fetch
globalThis.$fetch = $fetch
})