base.ts 258 B

12345678910
  1. import path from "path";
  2. import { createDefineMock } from "vite-plugin-mock-dev-server";
  3. export const defineMock = createDefineMock((mock) => {
  4. // 拼接url
  5. mock.url = path.join(
  6. import.meta.env.VITE_APP_BASE_API + "/api/v1/",
  7. mock.url
  8. );
  9. });