diff --git a/src/api/api.d.ts b/src/api/api.d.ts new file mode 100644 index 0000000..0709835 --- /dev/null +++ b/src/api/api.d.ts @@ -0,0 +1,9 @@ +interface Pagination { + size?: number + current?: number + total?: number +} + +interface BaseID { + id?: string +} \ No newline at end of file diff --git a/src/api/auth/auth.ts b/src/api/auth/auth.ts new file mode 100644 index 0000000..6ca55c7 --- /dev/null +++ b/src/api/auth/auth.ts @@ -0,0 +1,7 @@ +import { defHttp } from '~/utils/http' + +export function login() { + defHttp.post({ + url: '/api/auth/login', + }) +} diff --git a/vite.config.ts b/vite.config.ts index 1fe8884..1c36117 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -76,6 +76,7 @@ export default defineConfig({ 'src/composables', 'src/stores', 'src/types', + 'src/api/**', ], vueTemplate: true, resolvers: [