feat: Add request.ts (#2901)

* Add request.ts

* Update comments

* Refactor request filename
This commit is contained in:
anqiansong
2023-02-20 22:54:25 +08:00
committed by GitHub
parent 64ab00e8e3
commit 03d073a884
5 changed files with 159 additions and 2 deletions

View File

@@ -39,7 +39,7 @@ func genHandler(dir, webAPI, caller string, api *spec.ApiSpec, unwrapAPI bool) e
importCaller = "{ " + importCaller + " }"
}
if len(webAPI) > 0 {
imports += `import ` + importCaller + ` from ` + "\"" + webAPI + "\""
imports += `import ` + importCaller + ` from ` + `"./gocliRequest"`
}
if len(api.Types) != 0 {